public RemoveEnvironment ( Guid environmentId ) : void | ||
environmentId | Guid | |
Résultat | void |
public void StudioResourceRepository_RemoveEnvironment_ServerHasChildren_ServerIsRemovedFromTree() { //------------Setup for test-------------------------- var environmentId = Guid.NewGuid(); SetupEnvironmentRepo(environmentId); var repository = new StudioResourceRepository(GetTestData(), environmentId, _invoke); //------------Execute Test--------------------------- var countBeforeDisconnect = repository.ExplorerItemModels.Count; repository.RemoveEnvironment(environmentId); var countAfterDisconnect = repository.ExplorerItemModels.Count; //------------Assert Results------------------------- Assert.AreEqual(1, countBeforeDisconnect); Assert.AreEqual(0, countAfterDisconnect); }