public void TestSquareOccupiedFireHere() { Square square = new Square(); square.setState(State.miss); Assert.IsTrue(square.fireHere()); }
public void TestSquareGetterAndSetter() { Square square = new Square(); Random r = new Random(); int n = r.Next(-1, 100); int m = r.Next(-1, 100); square.setXLoc(n); square.setYLoc(m); square.setState(State.hit); Assert.IsTrue(square.getXLoc().Equals(n)); Assert.IsTrue(square.getYLoc().Equals(m)); Assert.IsTrue(square.getSquareState().Equals(State.hit)); }
public void TestSquareIsOccuppied() { Square square = new Square(); square.setState(State.miss); Assert.IsTrue(square.isOccuppied()); }