wearefrank / ladybug

Enable users of your application to debug and test it
Apache License 2.0
12 stars 8 forks source link

Add getWarningsAndErrors() to API #234

Closed mhdirkse closed 2 months ago

mhdirkse commented 2 months ago

Combined with ladybug-test-webapp PR https://github.com/wearefrank/ladybug-test-webapp/pull/16, the code of this PR was tested as follows:

$ curl -i http://localhost/ladybug/api/report/warningsAndErrors/errorGeneratingStorage
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100    52    0    52    0     0   5777      0 --:--:-- --:--:-- --:--:--  6500HTTP/1.1 200
Date: Fri, 03 May 2024 08:58:54 GMT
Content-Type: text/plain
Transfer-Encoding: chunked

A simulated error, should show up in the Ladybug GUI

This test will be automated in the Cypress tests of ladybug-frontend. This can be done if the error is properly shown in the GUI, as is the final intention of this PR.