File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -579,12 +579,13 @@ export function serverAudits(opts: ServerAuditOptions): Audit[] {
579579 ) ,
580580 audit (
581581 'BCF8' ,
582- 'MAY use 400 status code on JSON parsing failure' ,
582+ 'SHOULD use 400 status code on JSON parsing failure when accepting application/json ' ,
583583 async ( ) => {
584584 const res = await fetchFn ( await getUrl ( opts . url ) , {
585585 method : 'POST' ,
586586 headers : {
587587 'content-type' : 'application/json' ,
588+ accept : 'application/json' ,
588589 } ,
589590 body : '{ "not a JSON' ,
590591 } ) ;
Original file line number Diff line number Diff line change @@ -192,7 +192,7 @@ exports[`should not change globally unique audit ids 1`] = `
192192 } ,
193193 {
194194 " id" : " BCF8" ,
195- " name" : " MAY use 400 status code on JSON parsing failure" ,
195+ " name" : " SHOULD use 400 status code on JSON parsing failure when accepting application/json " ,
196196 } ,
197197 {
198198 " id" : " 8764" ,
You can’t perform that action at this time.
0 commit comments