public void InsertFrontPath_ShouldHandleTwoPathsWithSlash() { var builder = new UrlParts(serverUtil); builder.AppendPath("/something"); builder.InsertFrontPath("http://something/else/"); Assert.AreEqual("http://something/else/something", builder.BuildPath()); }
public void InsertFrontPath_ShouldKeepExistingPath() { var builder = new UrlParts(serverUtil, "controller", "action"); builder.PathInfo.Add("State").Add("FL"); builder.InsertFrontPath("http://something"); Assert.AreEqual("http://something/controller/action/State/FL", builder.BuildPath()); }