public bool PuzzleIsValid() { var action = new ActOnAllSegments(_puzzle); var validateSection = new ValidateSection(); return(action.Execute(validateSection)); }
private void ReduceCandidates() { var action = new ActOnAllSegments(_puzzle); var reduceCandidates = new ReduceCandidates(); while (!action.Execute(reduceCandidates)) { ; } }
private void Solve_WithGivenPuzzle_SolvesPuzzle(Puzzle puzzle) { var solver = new PuzzleSolver(puzzle); var acts = new ActOnAllSegments(puzzle); var printPuzzle = new PrintPuzzle(puzzle); solver.Solve(); printPuzzle.Print(); Assert.IsTrue(acts.Execute(new ValidateSection())); }