public void Monitor_Ping_Should_Return_Error_On_Invalid_Url() { //Arrange MonitorManager manager = new MonitorManager(); Monitor target = null; MonitorPingResult result = null; //Act manager.Initialize(); target = manager.CreateMonitor("Test of invalid url monitor", "htassatp://[email protected]"); result = target.Ping(); //Assert Assert.IsNotNull(result.Error); Assert.IsFalse(result.Succeeded); }
public void Monitor_Ping_Should_Return_PingResult_With_Out_Error() { //Arrange MonitorManager manager = new MonitorManager(); Monitor target = null; MonitorPingResult result = null; //Act manager.Initialize(); target = manager.CreateMonitor("Test of valid url monitor", "http://laumania.net"); result = target.Ping(); //Assert Assert.IsNotNull(result); Assert.IsNull(result.Error); Assert.IsTrue(result.Succeeded); }