Add UriBuilder test for no hostname.
authorDave Dunkin <dave.dunkin@logos.com>
Thu, 6 Aug 2015 18:55:46 +0000 (11:55 -0700)
committerDave Dunkin <dave.dunkin@logos.com>
Thu, 6 Aug 2015 18:55:46 +0000 (11:55 -0700)
mcs/class/System/Test/System/UriBuilderTest.cs

index d2c19e49830c1b32663bc58d826a8ef85776645b..a01e0accc2fb580acd4c5e279ea39f8b7b7625c3 100644 (file)
@@ -383,6 +383,13 @@ namespace MonoTests.System
                        // this is what ASP.NET really means (the ?)
                        Assert.AreEqual ("http://192.168.0.21/error404.aspx?aspxerrorpath=/WebResource.axd", ub.Uri.ToString ());
                }
+
+               [Test]
+               public void NoHostname ()
+               {
+                       UriBuilder ub = new UriBuilder ("about", null, -1, "config");
+                       Assert.AreEqual ("about:config", ub.ToString ());
+               }
        }
 }