public void LoadAllTest()
        {
            var exception = Record.Exception(() => {
                TextProcessingLoader.LoadAll();
            });

            Assert.Null(exception);
        }
Пример #2
0
        public TableCleanerModel()
        {
            var htmlToHtmlProcessing = new HtmlToHtmlProcessing();

            htmlToHtmlProcessing.TextToTextProcessing = TextProcessingLoader.Load("text-to-text.yml");

            TP = new TableCleanProcessing();
            TP.HtmlToHtmlProcessing     = htmlToHtmlProcessing;
            TP.TableCleanTextProcessing = TextProcessingLoader.Load("table-clean.yml");
        }
        public void RoundtripTest()
        {
            var exception = Record.Exception(() => {
                var tp         = TextProcessingLoader.Load("text-to-text.yml");
                var serializer = new TextProcessingSerializer();
                serializer.Serialize(tp);
            });

            Assert.Null(exception);
        }
        public void IfOptionCommandTest()
        {
            var TP = TextProcessingLoader.Load("if-option-command.yml", TestProcessingsPath);

            Assert.Equal("option1 is true;option2 is false;option3 is false;", TP.Process(""));
        }
Пример #5
0
        public void ExitCommandTest()
        {
            var TP = TextProcessingLoader.Load("exit-command.yml", TestProcessingsPath);

            Assert.Equal("This should happen.", TP.Process(""));
        }
        public void LoadTest()
        {
            var userProcessing = TextProcessingLoader.Load("hello-world.yml", "../../../resources/processings");

            Assert.Equal("Hello, another world!", userProcessing.Process(""));
        }
        public void LoadDefaultTest()
        {
            var defaultProcessing = TextProcessingLoader.LoadDefault("hello-world.yml", "../../../resources/processings");

            Assert.Equal("Hello, world!", defaultProcessing.Process(""));
        }