public void CreateSite_NullComponent_ThrowsArgumentNullException() { var owner = new Component(); var container = new SubNestedContainer(owner); AssertExtensions.Throws <ArgumentNullException>("component", () => container.CreateSiteEntryPoint(null, "name")); }
public void CreateSite_NullOwnerSite_Success(string name) { var component = new Component(); var owner = new Component(); var container = new SubNestedContainer(owner); INestedSite site = Assert.IsAssignableFrom <INestedSite>(container.CreateSiteEntryPoint(component, name)); Assert.Same(component, site.Component); Assert.Same(container, site.Container); Assert.False(site.DesignMode); Assert.Equal(name, site.Name); Assert.Equal(name, site.FullName); }