예제 #1
0
파일: SystemUri.cs 프로젝트: 0xCM/Meta.Core
 public static SystemUri Define
 (
     SchemeSegment scheme = null,
     HostSegment host     = null,
     PathSegment path     = null,
     QuerySegment query   = null
 ) => new SystemUri(scheme, host, path, query);
예제 #2
0
    public void SchemeSegment_AssertSegmentIsCorrect()
    {
        // Arrange
        var segement = new SchemeSegment();
        var context  = new RewriteContext {
            HttpContext = new DefaultHttpContext()
        };

        context.HttpContext.Request.Scheme = "http";
        // Act
        var results = segement.Evaluate(context, null, null);

        // Assert
        Assert.Equal("http", results);
    }