Exemplo n.º 1
0
        public void SolveBoard_16_Test()
        {
            Puzzle puzzle = GeneratePuzzle("aynedhecrtcaibkl", 8, 8); // cupboard roof oval

            IWordDictionary dictionary = GetDictionary();
            IBoardCop       boardCop   = new BoardCop.BoardCop();
            IBoardSolver    solver     = new BoardSolver.BoardSolver(boardCop, dictionary);
            PuzzleSolution  solutions  = solver.SolvePuzzle(puzzle);

            Assert.IsNotNull(solutions);
        }
Exemplo n.º 2
0
        public void SolveBoard_9_Test()
        {
            Puzzle puzzle = GeneratePuzzle("flfooirde", 4, 5); // roof field

            IWordDictionary dictionary = GetDictionary();
            IBoardCop       boardCop   = new BoardCop.BoardCop();
            IBoardSolver    solver     = new BoardSolver.BoardSolver(boardCop, dictionary);

            PuzzleSolution solutions = solver.SolvePuzzle(puzzle);

            Assert.IsNotNull(solutions);
        }
Exemplo n.º 3
0
        public void SolveBoard_9_Test_WrongFirstChoice()
        {
            Puzzle puzzle = GeneratePuzzle("efdidlrie", 4, 5); // ride field

            IWordDictionary dictionary = GetDictionary();
            IBoardCop       boardCop   = new BoardCop.BoardCop();
            IBoardSolver    solver     = new BoardSolver.BoardSolver(boardCop, dictionary);

            PuzzleSolution solutions = solver.SolvePuzzle(puzzle);

            Assert.IsNotNull(solutions);
        }
Exemplo n.º 4
0
        public void SolveBoard_4_Test()
        {
            Puzzle puzzle = GeneratePuzzle("cart", 4);

            IWordDictionary dictionary = GetDictionary();
            IBoardCop       boardCop   = new BoardCop.BoardCop();
            IBoardSolver    solver     = new BoardSolver.BoardSolver(boardCop, dictionary);

            PuzzleSolution ps = solver.SolvePuzzle(puzzle);

            Assert.IsNotNull(ps);
        }