public void Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Stream_Null() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); Func <Task <ITraktPostResponseNotFoundPerson> > postResponseNotFoundPerson = () => jsonReader.ReadObjectAsync(default(Stream)); postResponseNotFoundPerson.Should().Throw <ArgumentNullException>(); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Stream_Null() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(default(Stream)); postResponseNotFoundPerson.Should().BeNull(); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Json_String_Empty() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(string.Empty); postResponseNotFoundPerson.Should().BeNull(); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_JsonReader_Null() { var traktJsonReader = new PostResponseNotFoundPersonObjectJsonReader(); var postResponseNotFoundPerson = await traktJsonReader.ReadObjectAsync(default(JsonTextReader)); postResponseNotFoundPerson.Should().BeNull(); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Json_String_Not_Valid() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(JSON_NOT_VALID); postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().BeNull(); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Stream_Empty() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var stream = string.Empty.ToStream()) { var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(stream); postResponseNotFoundPerson.Should().BeNull(); } }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Stream_Not_Valid() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var stream = JSON_NOT_VALID.ToStream()) { var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(stream); postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().BeNull(); } }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_JsonReader_Empty() { var traktJsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var reader = new StringReader(string.Empty)) using (var jsonReader = new JsonTextReader(reader)) { var postResponseNotFoundPerson = await traktJsonReader.ReadObjectAsync(jsonReader); postResponseNotFoundPerson.Should().BeNull(); } }
public async Task Test_TraktPostResponseNotFoundPerson_From_Json() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(JSON) as TraktPostResponseNotFoundPerson; postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Trakt.Should().Be(297737U); postResponseNotFoundPerson.Ids.Slug.Should().Be("bryan-cranston"); postResponseNotFoundPerson.Ids.Imdb.Should().Be("nm0186505"); postResponseNotFoundPerson.Ids.Tmdb.Should().Be(17419U); postResponseNotFoundPerson.Ids.TvRage.Should().Be(1797U); }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_JsonReader_Not_Valid() { var traktJsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var reader = new StringReader(JSON_NOT_VALID)) using (var jsonReader = new JsonTextReader(reader)) { var postResponseNotFoundPerson = await traktJsonReader.ReadObjectAsync(jsonReader); postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().BeNull(); } }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_Stream_Complete() { var jsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var stream = JSON_COMPLETE.ToStream()) { var postResponseNotFoundPerson = await jsonReader.ReadObjectAsync(stream); postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Trakt.Should().Be(297737U); postResponseNotFoundPerson.Ids.Slug.Should().Be("bryan-cranston"); postResponseNotFoundPerson.Ids.Imdb.Should().Be("nm0186505"); postResponseNotFoundPerson.Ids.Tmdb.Should().Be(17419U); postResponseNotFoundPerson.Ids.TvRage.Should().Be(1797U); } }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_JsonReader_Complete() { var traktJsonReader = new PostResponseNotFoundPersonObjectJsonReader(); using (var reader = new StringReader(JSON_COMPLETE)) using (var jsonReader = new JsonTextReader(reader)) { var postResponseNotFoundPerson = await traktJsonReader.ReadObjectAsync(jsonReader); postResponseNotFoundPerson.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Should().NotBeNull(); postResponseNotFoundPerson.Ids.Trakt.Should().Be(297737U); postResponseNotFoundPerson.Ids.Slug.Should().Be("bryan-cranston"); postResponseNotFoundPerson.Ids.Imdb.Should().Be("nm0186505"); postResponseNotFoundPerson.Ids.Tmdb.Should().Be(17419U); postResponseNotFoundPerson.Ids.TvRage.Should().Be(1797U); } }
public async Task Test_PostResponseNotFoundPersonObjectJsonReader_ReadObject_From_JsonReader_Null() { var traktJsonReader = new PostResponseNotFoundPersonObjectJsonReader(); Func <Task <ITraktPostResponseNotFoundPerson> > postResponseNotFoundPerson = () => traktJsonReader.ReadObjectAsync(default(JsonTextReader)); await postResponseNotFoundPerson.Should().ThrowAsync <ArgumentNullException>(); }