aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAlbert Krewinkel <albert@zeitkraut.de>2021-02-22 23:56:04 +0100
committerAlbert Krewinkel <albert@zeitkraut.de>2021-02-22 23:56:04 +0100
commit00e4bb51e47487fa146caee3bcbbacef51292acc (patch)
tree3962767c473dbfc8e80b99adb3c47e5636301d6e /test
parentd30791a38166538be60a134196f1d2675275017d (diff)
downloadpandoc-00e4bb51e47487fa146caee3bcbbacef51292acc.tar.gz
tests: print accurate location if a test fails
Ensures that tasty-hunit reports the location of the failing test instead of the location of the helper `test` function.
Diffstat (limited to 'test')
-rw-r--r--test/Tests/Helpers.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/Tests/Helpers.hs b/test/Tests/Helpers.hs
index 31e727a66..64c2785ed 100644
--- a/test/Tests/Helpers.hs
+++ b/test/Tests/Helpers.hs
@@ -35,7 +35,7 @@ import Text.Pandoc.Shared (trimr)
import Text.Pandoc.Writers.Native (writeNative)
import Text.Printf
-test :: (ToString a, ToString b, ToString c)
+test :: (ToString a, ToString b, ToString c, HasCallStack)
=> (a -> b) -- ^ function to test
-> String -- ^ name of test case
-> (a, c) -- ^ (input, expected value)