internal static void SetDefault(Builder builder) { builder.Commands.Clear(); builder.Commands.Add(CommandsBuilder.BuildClear()); builder.Commands.Add(CommandsBuilder.BuildCurrentDirectory()); builder.Commands.Add(CommandsBuilder.BuildTexo()); builder.Commands.Add(CommandsBuilder.BuildHelp()); builder.DefaultCommand = string.Empty; }
public void InputTree_BuildCurrentDirectory_CurrentDirectoryTree() { InputTreeBuilder builder = new InputTreeBuilder(new EmptyLogService()); InputTree tree = builder.Build(new[] { CommandsBuilder.BuildCurrentDirectory() }, null); Assert.NotNull(tree); Assert.NotNull(tree.Root); Assert.Equal(4, tree.Root.Queries.Count); Assert.Null(tree.Root.DefaultQuery); Assert.Single(tree.Root.Queries["cd"].Parameters); }