Welcome to mirror list, hosted at ThFree Co, Russian Federation.

BarebonesMatcherConformanceTest.cs « Matching « UnitTests « test « Routing « Http « src - github.com/dotnet/aspnetcore.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 964a3d221e48adc0c9bd9fe0cf367a2f64b4f993 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using System;
using System.Threading.Tasks;
using Xunit;

namespace Microsoft.AspNetCore.Routing.Matching;

public class BarebonesMatcherConformanceTest : MatcherConformanceTest
{
    // Route values not supported
    [Fact]
    public override Task Match_SingleParameter()
    {
        return Task.CompletedTask;
    }

    // Route values not supported
    [Fact]
    public override Task Match_SingleParameter_TrailingSlash()
    {
        return Task.CompletedTask;
    }

    // Route values not supported
    [Fact]
    public override Task Match_SingleParameter_WeirdNames()
    {
        return Task.CompletedTask;
    }

    // Route values not supported
    [Theory]
    [InlineData(null, null, null, null)]
    public override Task Match_MultipleParameters(string template, string path, string[] keys, string[] values)
    {
        GC.KeepAlive(new object[] { template, path, keys, values });
        return Task.CompletedTask;
    }

    // Route constraints not supported
    [Fact]
    public override Task Match_Constraint()
    {
        return Task.CompletedTask;
    }

    internal override Matcher CreateMatcher(params RouteEndpoint[] endpoints)
    {
        var builder = new BarebonesMatcherBuilder();
        for (var i = 0; i < endpoints.Length; i++)
        {
            builder.AddEndpoint(endpoints[i]);
        }
        return builder.Build();
    }
}