@@ -69,7 +69,8 @@ public void ParseDocumentFromInlineStringShouldSucceed()
6969 Assert . Equivalent (
7070 new OpenApiDiagnostic ( )
7171 {
72- SpecificationVersion = OpenApiSpecVersion . OpenApi3_0
72+ SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 ,
73+ Format = OpenApiConstants . Yaml
7374 } , result . Diagnostic ) ;
7475 }
7576
@@ -147,7 +148,8 @@ public async Task ParseBrokenMinimalDocumentShouldYieldExpectedDiagnostic()
147148 {
148149 new OpenApiValidatorError ( nameof ( OpenApiInfoRules . InfoRequiredFields ) , "#/info/title" , "The field 'title' in 'info' object is REQUIRED." )
149150 } ,
150- SpecificationVersion = OpenApiSpecVersion . OpenApi3_0
151+ SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 ,
152+ Format = OpenApiConstants . Yaml
151153 } , result . Diagnostic ) ;
152154 }
153155
@@ -170,7 +172,8 @@ public async Task ParseMinimalDocumentShouldSucceed()
170172 Assert . Equivalent (
171173 new OpenApiDiagnostic ( )
172174 {
173- SpecificationVersion = OpenApiSpecVersion . OpenApi3_0
175+ SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 ,
176+ Format = OpenApiConstants . Yaml
174177 } , result . Diagnostic ) ;
175178 }
176179
@@ -557,7 +560,7 @@ public async Task ParseStandardPetStoreDocumentShouldSucceed()
557560 actual . Document . Should ( ) . BeEquivalentTo ( expectedDoc , options => options . Excluding ( x => x . Workspace ) . Excluding ( y => y . BaseUri ) ) ;
558561
559562 Assert . Equivalent (
560- new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 } , actual . Diagnostic ) ;
563+ new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 , Format = OpenApiConstants . Yaml } , actual . Diagnostic ) ;
561564 }
562565
563566 [ Fact ]
@@ -1031,7 +1034,7 @@ [new OpenApiSecuritySchemeReference("securitySchemeName2")] =
10311034 . Excluding ( y => y . BaseUri ) ) ;
10321035
10331036 Assert . Equivalent (
1034- new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 } , actual . Diagnostic ) ;
1037+ new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 , Format = OpenApiConstants . Yaml } , actual . Diagnostic ) ;
10351038 }
10361039
10371040 [ Fact ]
@@ -1042,7 +1045,7 @@ public async Task ParsePetStoreExpandedShouldSucceed()
10421045 // TODO: Create the object in memory and compare with the one read from YAML file.
10431046
10441047 Assert . Equivalent (
1045- new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 } , actual . Diagnostic ) ;
1048+ new OpenApiDiagnostic ( ) { SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 , Format = OpenApiConstants . Yaml } , actual . Diagnostic ) ;
10461049 }
10471050
10481051 [ Fact ]
@@ -1444,9 +1447,10 @@ public void ParseBasicDocumentWithServerVariableShouldSucceed()
14441447 } ;
14451448
14461449 Assert . Equivalent (
1447- new OpenApiDiagnostic
1448- {
1449- SpecificationVersion = OpenApiSpecVersion . OpenApi3_0
1450+ new OpenApiDiagnostic
1451+ {
1452+ SpecificationVersion = OpenApiSpecVersion . OpenApi3_0 ,
1453+ Format = OpenApiConstants . Yaml
14501454 } , result . Diagnostic ) ;
14511455
14521456 result . Document . Should ( ) . BeEquivalentTo ( expected , options => options . Excluding ( x => x . BaseUri ) ) ;
0 commit comments