File tree Expand file tree Collapse file tree 1 file changed +0
-23
lines changed
Expand file tree Collapse file tree 1 file changed +0
-23
lines changed Original file line number Diff line number Diff line change @@ -30,29 +30,6 @@ describe("GraphErrorHandler.ts", () => {
3030 } ) ;
3131 } ) ;
3232
33- describe ( "constructErrorFromRawResponse" , async ( ) => {
34- it ( "Should parse error from raw response" , async ( ) => {
35- const body = "unauthorized" ;
36- const statusCode = 401 ;
37- const errorResponse = new Response ( body , {
38- status : statusCode ,
39- } ) ;
40- const gError = await GraphErrorHandler [ "constructErrorFromRawResponse" ] ( errorResponse , statusCode ) ;
41- assert . equal ( gError . statusCode , statusCode ) ;
42- assert . equal ( gError . body , body ) ;
43- } ) ;
44-
45- it ( "Should parse error without body" , async ( ) => {
46- const statusCode = 401 ;
47- const errorResponse = new Response ( undefined , {
48- status : statusCode ,
49- } ) ;
50- const gError = await GraphErrorHandler [ "constructErrorFromRawResponse" ] ( errorResponse , statusCode ) ;
51- assert . equal ( gError . statusCode , statusCode ) ;
52- assert . isNull ( gError . body ) ;
53- } ) ;
54- } ) ;
55-
5633 describe ( "constructErrorFromResponse" , ( ) => {
5734 const statusCode = 400 ;
5835 const error : any = {
You can’t perform that action at this time.
0 commit comments