Fix for rare mono runtime crash during shutdown sequence on Windows.
[mono.git] / mcs / class / System / Test / System.Net.NetworkInformation / PingTest.cs
1 using NUnit.Framework;
2 using System;
3 using System.Net.NetworkInformation;
4
5 namespace MonoTests.System.Net.NetworkInformation
6 {
7         [TestFixture]
8         public class PingTest
9         {
10                 [Test] 
11                 public void PingFail()
12                 {
13 #if MONOTOUCH
14                         Assert.Ignore ("Ping implementation is broken on MT (requires sudo access)");
15 #else
16                         var p = new Ping ().Send ("192.0.2.0");
17                         Assert.AreNotEqual(IPStatus.Success, p.Status);
18 #endif
19                 }
20
21                 [Test]
22                 public void PingSuccess()
23                 {
24 #if MONOTOUCH
25                         Assert.Ignore ("Ping implementation is broken on MT (requires sudo access)");
26 #else
27                         var p = new Ping ().Send ("127.0.0.1");
28                         Assert.AreEqual(IPStatus.Success, p.Status);
29 #endif
30                 }               
31         }
32 }
33