Skip to content

Commit

Permalink
coverlet complaining again
Browse files Browse the repository at this point in the history
it's getting more and more tempting to exclude Newtonsoft from requirements :)
  • Loading branch information
Todd committed Dec 8, 2023
1 parent bd17571 commit ad46151
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/Flurl.Test/Http/NewtonsoftTests.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
using System;
using System.Net.Http;
using NUnit.Framework;
using Flurl.Http;
using Flurl.Http.Newtonsoft;
using Flurl.Http.Testing;
using System.Threading.Tasks;
using Flurl.Http.Configuration;
using Newtonsoft.Json;
using NUnit.Framework.Constraints;

namespace Flurl.Test.Http
{
Expand Down Expand Up @@ -55,6 +57,14 @@ public async Task null_response_returns_null_dynamic() {

var list = await resp.ReceiveJsonList();
Assert.IsNull(list);

var ex = new FlurlHttpException(new FlurlCall {
Request = new FlurlRequest(),
HttpRequestMessage = new HttpRequestMessage(),
Response = null,
});
var err = await ex.GetResponseJsonAsync();
Assert.IsNull(err);
}

[TestCase(false)]
Expand Down

0 comments on commit ad46151

Please sign in to comment.