File tree 3 files changed +2
-7
lines changed
src/JsonApiDotNetCore/Controllers
test/JsonApiDotNetCoreExampleTests/Acceptance
3 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -201,7 +201,7 @@ public virtual async Task<IActionResult> DeleteAsync(TId id)
201
201
if ( ! wasDeleted )
202
202
return NotFound ( ) ;
203
203
204
- return Ok ( ) ;
204
+ return NoContent ( ) ;
205
205
}
206
206
207
207
private IQueryable < T > ApplySortAndFilterQuery ( IQueryable < T > entities )
Original file line number Diff line number Diff line change 1
- using System . Collections . Generic ;
2
1
using System . Linq ;
3
2
using System . Net ;
4
3
using System . Net . Http ;
5
- using System . Net . Http . Headers ;
6
4
using System . Threading . Tasks ;
7
5
using Bogus ;
8
6
using DotNetCoreDocs ;
9
7
using DotNetCoreDocs . Writers ;
10
- using JsonApiDotNetCore . Serialization ;
11
- using JsonApiDotNetCore . Services ;
12
8
using JsonApiDotNetCoreExample ;
13
9
using JsonApiDotNetCoreExample . Data ;
14
10
using JsonApiDotNetCoreExample . Models ;
15
11
using Microsoft . AspNetCore . Hosting ;
16
12
using Microsoft . AspNetCore . TestHost ;
17
- using Newtonsoft . Json ;
18
13
using Xunit ;
19
14
20
15
namespace JsonApiDotNetCoreExampleTests . Acceptance . Spec
Original file line number Diff line number Diff line change @@ -424,7 +424,7 @@ public async Task Can_Delete_TodoItem()
424
424
var response = await _fixture . MakeRequest < TodoItem > ( description , request ) ;
425
425
426
426
// Assert
427
- Assert . Equal ( HttpStatusCode . OK , response . StatusCode ) ;
427
+ Assert . Equal ( HttpStatusCode . NoContent , response . StatusCode ) ;
428
428
Assert . Null ( _context . TodoItems . FirstOrDefault ( t => t . Id == todoItem . Id ) ) ;
429
429
}
430
430
}
You can’t perform that action at this time.
0 commit comments