Пример #1
0
        public void TestWritePuzzle4x4()
        {
            string expected = "4\r\n1 2 3 4 \r\n4 2 - 1 \r\n- - - 2 \r\n3 - 2 - \r\n- 4 - 3 \r\n";

            PuzzleWriter.WritePuzzle("testPuzzle.txt", puzzle);
            string actual = File.ReadAllText("testPuzzle.txt");

            Assert.AreEqual(expected, actual);
        }
Пример #2
0
 public void TestWritePuzzleNullPuzzle()
 {
     PuzzleWriter.WritePuzzle("testPuzzle.txt", null);
     Assert.IsFalse(File.Exists("testPuzzle.txt"));
 }
Пример #3
0
 public void TestWritePuzzleNullFile()
 {
     PuzzleWriter.WritePuzzle(null, puzzle);
 }