示例#1
0
        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());
        }
示例#2
0
        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());
        }