ITADN

sydtest-hspec: `shouldBe` failure output

#103Closedsgillespie 创建于 2024-12-28
S
sgillespiecommented
When using `fromHspec` and getting a comparison failure, I expect the failure output to be the usual helpful diff message: ``` Expected these values to be equal: Actual: 8 Expected: 6 ``` However, what I actually see is: ``` Failures: src/Test/Syd/Hspec.hs:68 ✗ 1 Test.Syd.HspecSpec.exampleHspecSpec.adds 3 and 5 together in io Retries: 3 (does not look flaky) Contextual "NotEqualButShouldHaveBeenEqualWithDiff \"8\" \"6\" (Just [First \"8\",Second \"6\"])" "test/Test/Syd/HspecSpec.hs:19:44" ``` I'm new to sydtest, so it's possible I'm doing something wrong, although it _looks_ like a bug. I suspect the culplrit is [here](https://github.com/NorfairKing/sydtest/blob/master/sydtest-hspec/src/Test/Syd/Hspec.hs#L146)
关闭于 2025-01-07 4 条评论