public void Can_delete_website() { WebsiteController websiteController = new WebsiteController(new Website { Name = "test_site", Server = "localhost" }); websiteController.Delete(); Assert.False(websiteController.Exists()); }
public void Can_tell_if_website_exists() { WebsiteController websiteController = new WebsiteController(new Website{Name = "test_site", Server = "localhost"}); bool exist = websiteController.Exists(); Assert.False(exist); }
public void Website_exists_after_creating() { WebsiteController websiteController = new WebsiteController(new Website { Name = "test_site", Server = "localhost" }); websiteController.Create(); bool exist = websiteController.Exists(); Assert.True(exist); }
public void Dispose() { WebsiteController websiteController = new WebsiteController(new Website { Name = "test_site"}); websiteController.Delete(); Assert.False(websiteController.Exists()); }
public void Can_create_iis_website_given_name() { WebsiteController websiteController = new WebsiteController(new Website{Server = "localhost", Name = "test_site", Home = test_site, Port = 8888}); int websiteId = websiteController.Create(); Assert.True(websiteId > 0); string html = Helper.GetSite("http://localhost:8888/"); Assert.Contains("Hello World", html); }