Skip to content

Commit 14e3a40

Browse files
dermotblaircaRehanSaeed
authored andcommitted
Update ValuesJsonConverterTest.cs
Seeing if RelativeOrAbsolute fixes unit tests
1 parent c32d98a commit 14e3a40

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Tests/Schema.NET.Test/ValuesJsonConverterTest.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ public void ReadJson_ParseValueToken_RelativeUriAsString()
268268
{
269269
var json = "{\"Property\":\"/Thing\"}";
270270
var result = DeserializeObject<Values<string, Uri>>(json);
271-
Assert.Equal(new Uri("/Thing", UriKind.Relative), result.Value2.First());
271+
Assert.Equal(new Uri("/Thing", UriKind.RelativeOrAbsolute), result.Value2.First());
272272
}
273273

274274
[Fact]
@@ -294,7 +294,7 @@ public void ReadJson_Values_SingleValue_ThingInterface()
294294
Assert.Equal(new Uri("https://example.com/book/1"), ((Book)actual).Id);
295295
Assert.Equal("The Catcher in the Rye", actual.Name);
296296
Assert.Equal(new Uri("https://www.barnesandnoble.com/store/info/offer/JDSalinger"), (Uri)actual.Url!);
297-
Assert.Equal(new Uri("/images/book/1", UriKind.Relative), (Uri)actual.Image!);
297+
Assert.Equal(new Uri("/images/book/1", UriKind.RelativeOrAbsolute), (Uri)actual.Image!);
298298
var author = Assert.Single(actual.Author.Value2);
299299
Assert.Equal("J.D. Salinger", author.Name);
300300
}

0 commit comments

Comments
 (0)