Пример #1
0
        public void ZeroTestMainMethod()
        {
            var streamWriter = new StreamWriter(@"..\..\result0.txt");

            using (streamWriter)
            {
                Console.SetIn(new StreamReader(@"..\..\test.000.001.in.txt"));
                Console.SetOut(streamWriter);
                HTMLRendererCommandExecutor.Main();
            }

            Assert.AreEqual(new StreamReader(@"..\..\result0.txt").ReadToEnd(),
                            new StreamReader(@"..\..\test.000.001.out.txt").ReadToEnd());
        }
Пример #2
0
        public void Test5MainMethod()
        {
            int testNumber   = 5;
            var streamWriter = new StreamWriter(string.Format(@"..\..\result{0}.txt", testNumber));

            using (streamWriter)
            {
                Console.SetIn(new StreamReader(string.Format(@"..\..\test.00{0}.in.txt", testNumber)));
                Console.SetOut(streamWriter);
                HTMLRendererCommandExecutor.Main();
            }

            Assert.AreEqual(new StreamReader(string.Format(@"..\..\result{0}.txt", testNumber)).ReadToEnd(),
                            new StreamReader(string.Format(@"..\..\test.00{0}.out.txt", testNumber)).ReadToEnd());
        }