public void EnsureHubThrowsWhenCantResolve() { var resolver = new DefaultDependencyResolver(); var hubManager = new DefaultHubManager(resolver); Assert.Throws <InvalidOperationException>(() => hubManager.EnsureHub("__ELLO__")); }
public void EnsureHubSuccessfullyResolves() { var resolver = new DefaultDependencyResolver(); var hubManager = new DefaultHubManager(resolver); var TestHubName = "CoreTestHubWithMethod"; HubDescriptor hub = null, actualDescriptor = hubManager.GetHub(TestHubName); hub = hubManager.EnsureHub(TestHubName); Assert.Equal(hub, actualDescriptor); }