public void CellConstructorTest() { /*** ARRANGE ***/ Alphabet alphabet = null; // TODO: Initialize to an appropriate value /*** ACT ***/ Cell target = new Cell(alphabet); /*** ASSERT ***/ Assert.Inconclusive("TODO: Implement code to verify target"); }
public void CanBeTest() { Alphabet alphabet = null; // TODO: Initialize to an appropriate value Cell target = new Cell(alphabet); // TODO: Initialize to an appropriate value int value = 0; // TODO: Initialize to an appropriate value bool expected = false; // TODO: Initialize to an appropriate value bool actual; actual = target.CanBe(value); Assert.AreEqual(expected, actual); Assert.Inconclusive("Verify the correctness of this test method."); }
/// <summary> /// Raises the CellSolved event. /// </summary> protected virtual void OnCellSolved(Cell cell) { this.SolveCount++; var e = CellSolved; if (e != null) e(this, new CellEventArgs(cell)); }
/// <summary> /// Raises the CellChanged event. /// </summary> protected virtual void OnCellChanged(Cell cell) { var e = CellChanged; if (e != null) e(this, new CellEventArgs(cell)); }
public void ReportCellSolved(Cell cell) { OnCellSolved(cell); }
public void ReportCellChanged(Cell cell) { OnCellChanged(cell); }
public void IsSolvedTest() { Alphabet alphabet = null; // TODO: Initialize to an appropriate value Cell target = new Cell(alphabet); // TODO: Initialize to an appropriate value bool actual; actual = target.IsSolved; Assert.Inconclusive("Verify the correctness of this test method."); }
public void ValueTest() { /*** ARRANGE ***/ Alphabet alphabet = CreateDefaultAlphabet(); Cell target = new Cell(alphabet); int expected = 3; // arbitrary int actual; /*** ACT ***/ target.Value = expected; /*** ASSERT ***/ actual = target.Value; Assert.AreEqual(expected, actual); // value setting successful alphabet.Remove(expected); // cell can be no other value foreach (int value in alphabet) Assert.IsFalse(target.CanBe(value)); }
public void RemovePossibilityTest() { /*** ARRANGE ***/ Alphabet alphabet = CreateDefaultAlphabet(); Cell target = new Cell(alphabet); int value = 3; // arbitrary /*** ACT ***/ target.RemovePossibility(value); /*** ASSERT ***/ Assert.IsFalse(target.CanBe(value)); // value is no longer a possible value Assert.IsTrue(alphabet.Contains(value)); // alphabet remains unchanged }