public void Nap_WithSetup_AndConfiguraiton_CreatesNewNap_WithSetupApplied_And_PluginMethodsRun() { // Arrange var setup = new NapSetup(); setup.InstallPlugin(_plugin); // Act var nap = new NapClient(_config, setup); var request = nap.Get("test"); // Assert Assert.Same(_config, nap.Config); A.CallTo(() => _plugin.Configure(A <INapConfig> ._)).MustHaveHappened(); A.CallTo(() => _plugin.Prepare(A <NapRequest> ._)).MustNotHaveHappened(); A.CallTo(() => _plugin.Execute <Result>(A <INapRequest> ._)).MustNotHaveHappened(); A.CallTo(() => _plugin.Process(A <NapResponse> ._)).MustNotHaveHappened(); }
// Tests to ensure that *.config files get parsed correctly. public NapConfigurationTests() { _setup = new NapSetup(); _setup.InstallPlugin <NapConfigurationPlugin>(); }