public void CannotEnterEconomicModeTwice() { var selector = new ResponsivenessModeSelector(); Assert.Throws <DomainRuleViolatedException>(() => { selector.EnterEconomic(); selector.EnterEconomic(); }); }
public void EnteringEconomicModeResultsInEvent() { var selector = new ResponsivenessModeSelector(); var events = selector.EnterEconomic(); Assert.True(events.Any(x => x is EconomicModeEntered)); }