[SetUp]\r
public void GetReady () \r
{\r
+#if !FEATURE_NO_BSD_SOCKETS\r
maxIdle = ServicePointManager.MaxServicePointIdleTime;\r
ServicePointManager.MaxServicePointIdleTime = 10;\r
+#endif\r
googleUri = new Uri ("http://www.google.com");\r
yahooUri = new Uri ("http://www.yahoo.com");\r
apacheUri = new Uri ("http://www.apache.org");\r
[TearDown]\r
public void Finish ()\r
{\r
+#if !FEATURE_NO_BSD_SOCKETS\r
ServicePointManager.MaxServicePointIdleTime = maxIdle;\r
+#endif\r
}\r
\r
[Test, ExpectedException (typeof (InvalidOperationException))]\r
}\r
\r
[Test]\r
+#if FEATURE_NO_BSD_SOCKETS\r
+ [ExpectedException (typeof (PlatformNotSupportedException))]\r
+#endif\r
public void FindServicePoint ()\r
{\r
ServicePointManager.MaxServicePoints = 0;\r
ServicePoint sp = ServicePointManager.FindServicePoint (googleUri, new WebProxy (apacheUri));\r
Assert.AreEqual (apacheUri, sp.Address, "#1");\r
-#if NET_2_1 && !MONODROID\r
+#if MOBILE && !MONODROID\r
Assert.AreEqual (10, sp.ConnectionLimit, "#2");\r
#else\r
Assert.AreEqual (2, sp.ConnectionLimit, "#2");\r