public void RemoveStarSystem_SystemIsValid_SystemRemoved() { var mockSystem = new Mock <StarSystem>("name", new List <Star>(), new List <Planet>()).Object; var container = new StarSystemContainer(); Assert.AreEqual(0, container.StarSystemsCount); container.AddStarSystem(mockSystem); Assert.AreEqual(1, container.StarSystemsCount); container.RemoveStarSystem(mockSystem); Assert.AreEqual(0, container.StarSystemsCount); }
public void RemoveStarSystem_SystemIsNotInContainer_NoChanges() { var mockInContainer = new Mock <StarSystem>("name", new List <Star>(), new List <Planet>()).Object; var mockNotInContainer = new Mock <StarSystem>("name", new List <Star>(), new List <Planet>()).Object; var container = new StarSystemContainer(); Assert.AreEqual(0, container.StarSystemsCount); container.AddStarSystem(mockInContainer); Assert.AreEqual(1, container.StarSystemsCount); container.RemoveStarSystem(mockNotInContainer); Assert.AreEqual(1, container.StarSystemsCount); }