more error message regression tests

This commit is contained in:
Tom Sydney Kerckhove 2021-11-06 11:06:38 +01:00
parent ccd5a05ef7
commit ca78d92a3b
3 changed files with 4 additions and 0 deletions

View File

@ -71,7 +71,9 @@ spec = do
aesonCodecSpec @Fruit
aesonCodecSpec @Example
aesonCodecErrorSpec @Example "example-error-bool-number" "{\"text\": \"hello\", \"bool\": 5}"
aesonCodecErrorSpec @Example "example-error-fruit-number" "{\"text\": \"hello\", \"bool\": true, \"maybe\": null, \"fruit\": 5}"
aesonCodecSpec @Recursive
aesonCodecErrorSpec @Recursive "recursive-error-recurse-string" "{\"recurse\": {\"recurse\": {\"recurse\": \"hello\"}}}"
aesonCodecSpec @Via
aesonCodecSpec @VeryComment

View File

@ -0,0 +1 @@
Error in $: parsing Text failed, expected String, but encountered Number

View File

@ -0,0 +1 @@
Error in $: parsing Recurse failed, expected Object, but encountered String