public void GetUser_ReturnsSingleInstance() { // Act IWebHookUser actual1 = CustomServices.GetUser(); IWebHookUser actual2 = CustomServices.GetUser(); // Assert Assert.Same(actual1, actual2); }
public void SetUser_GetUser_Roundtrips() { // Arrange Mock <IWebHookUser> userMock = new Mock <IWebHookUser>(); // Act CustomServices.SetUser(userMock.Object); IWebHookUser actual = CustomServices.GetUser(); // Assert Assert.Same(userMock.Object, actual); }