burnash / gspread

Google Sheets Python API
https://docs.gspread.org
MIT License
7.06k stars 945 forks source link

Add test on receiving an invalid JSON in the APIError exception handler. #1512

Closed lavigne958 closed 1 week ago

lavigne958 commented 1 week ago

Manually build an invalid JSON body. Using HTML to fake using the wrong endpoint that returns HTML instead of JSON.

Use that new http client to do some request and make sure the error matches.

alifeee commented 1 week ago

looks splendid ! :)