4
4
using System . Collections . Generic ;
5
5
using System . Linq ;
6
6
using FluentAssertions ;
7
- using Microsoft . OpenApi . Any ;
8
7
using Microsoft . OpenApi . Models ;
9
8
using Microsoft . OpenApi . Services ;
10
9
using Xunit ;
@@ -15,43 +14,6 @@ namespace Microsoft.OpenApi.Tests.Services
15
14
[ Collection ( "DefaultSettings" ) ]
16
15
public class OpenApiComparerTests
17
16
{
18
- public static OpenApiExample AdvancedExample = new OpenApiExample
19
- {
20
- Value = new OpenApiObject
21
- {
22
- [ "versions" ] = new OpenApiArray
23
- {
24
- new OpenApiObject
25
- {
26
- [ "status" ] = new OpenApiString ( "Status1" ) ,
27
- [ "id" ] = new OpenApiString ( "v1" ) ,
28
- [ "links" ] = new OpenApiArray
29
- {
30
- new OpenApiObject
31
- {
32
- [ "href" ] = new OpenApiString ( "http://example.com/1" ) ,
33
- [ "rel" ] = new OpenApiString ( "sampleRel1" )
34
- }
35
- }
36
- } ,
37
-
38
- new OpenApiObject
39
- {
40
- [ "status" ] = new OpenApiString ( "Status2" ) ,
41
- [ "id" ] = new OpenApiString ( "v2" ) ,
42
- [ "links" ] = new OpenApiArray
43
- {
44
- new OpenApiObject
45
- {
46
- [ "href" ] = new OpenApiString ( "http://example.com/2" ) ,
47
- [ "rel" ] = new OpenApiString ( "sampleRel2" )
48
- }
49
- }
50
- }
51
- }
52
- }
53
- } ;
54
-
55
17
private readonly ITestOutputHelper _output ;
56
18
57
19
public OpenApiComparerTests ( ITestOutputHelper output )
@@ -71,8 +33,6 @@ public void OpenApiComparerShouldSucceed(
71
33
{
72
34
_output . WriteLine ( testCaseName ) ;
73
35
74
- new OpenApiExampleComparer ( ) . Compare ( AdvancedExample , AdvancedExample ,
75
- new ComparisonContext ( new OpenApiComparerFactory ( ) , new OpenApiDocument ( ) , new OpenApiDocument ( ) ) ) ;
76
36
var differences = OpenApiComparer . Compare ( source , target ) . ToList ( ) ;
77
37
differences . Count ( ) . Should ( ) . Be ( expectedDifferences . Count ) ;
78
38
0 commit comments