public void EnvironmentNameMustNotCallGetEnvironmentNameOnceEnvironmentNameHasBeenDetermined() { MockRuntimeContext context = new MockRuntimeContext(); Assert.Equal(string.Empty, context.EnvironmentName); int expected = context.GetEnvironmentNameCalled; Assert.Equal(string.Empty, context.EnvironmentName); Assert.Equal(expected, context.GetEnvironmentNameCalled); }
public void ApplicationNameMustNotCallGetApplicationNameOnceApplicationNameHasBeenDetermined() { MockRuntimeContext context = new MockRuntimeContext(); Assert.Equal(AppDomain.CurrentDomain.FriendlyName, context.ApplicationName); int expected = context.GetApplicationNameCalled; Assert.Equal(AppDomain.CurrentDomain.FriendlyName, context.ApplicationName); Assert.Equal(expected, context.GetApplicationNameCalled); }