/Location Constructor Tests Secret
Last active
December 9, 2015 12:19
ConstructorTests
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[TestMethod] | |
public void Location_is_constructed_with_correct_Id() | |
{ | |
Location location = new Location(1); | |
Assert.AreEqual(1, location.Id); | |
} | |
[TestMethod] | |
public void Location_is_constructed_with_all_exits_set_to_no_exit() | |
{ | |
Location location = new Location(1); | |
Assert.AreEqual(-1, location.ExitInDirection(0)); | |
Assert.AreEqual(-1, location.ExitInDirection(1)); | |
Assert.AreEqual(-1, location.ExitInDirection(2)); | |
Assert.AreEqual(-1, location.ExitInDirection(3)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment