- Fixes for launching external processes (like diff) on Windows
- Update the golden file on --accept if decoding the golden file failed with an exception
- Do not depend on unix-compat
- Add an option to remove the output file after a test has run, if there is a golden file, or one has been created
- Fix a bug where
goldenVsFileDiff
would not create a missing golden file
- Fix a bug where the
TASTY_SIZE_CUTOFF
env. variable would be ignored
- Fix a bug with UTF-8 output
- Expose
createDirectoriesAndWriteFile
- Add
--size-cutoff
to truncate large golden test output - Restore support for GHC >= 7.8
Create missing directories when writing golden files
Add a --no-create
flag
Make the environment variable TASTY_ACCEPT=True
work, and make the value
case-insensitive (so TASTY_ACCEPT=true
works, too)
Docs: link to an introductory blog post
Fix compatibility with optparse-applicative-0.13
Intercept exceptions thrown by the test, adhering to the new tasty API contract.
Switch from temporary-rc to temporary
Impose a lower bound version constraint on bytestring.
-
Accepting tests is no longer done by a separate ingredient; instead it is now an option that affects tests themselves.
--accept
used to run only golden tests; now all tests are run, but only golden tests are affected by this option- when accepting, all the usual options apply (such as
-j
) - when accepting, the interace is the same as when running
defaultMain
andacceptingTests
are kept for compatibility, but do not do anything and are obsolete
-
When a golden test file does not exist, it is created automatically, even when
--accept
is not specified. You'll see a message likeUnboxedTuples: OK (0.04s) Golden file did not exist; created
-
No longer use lazy IO
ValueGetter
type is gone (replaced byIO
)- Because of that, the type of the primitive
goldenTest
is changed vgReadFile
function is gone (replaced byData.ByteString.readFile
)
- Warn when some tests threw exceptions during
--accept
- Properly handle exceptions; don't swallow Ctrl-C
Restore compatibility with older compilers
Relax Cabal
dependency
Add findByExtension
Catch exceptions when accepting golden tests
Switch to temporary-rc
- Fix a bug where the result of the comparison function would reference yet unread data from a semiclosed file and the file gets closed, leading to a runtime exception
- Export
writeBinaryFile
- Improve the docs
- Update to work with
tasty-0.8
Update to work with tasty-0.7
Update to work with tasty-0.5
Migrate to ingredients
Add goldenVsStringDiff
Update to work with tasty-0.2
Initial release of tasty-golden
(derived from test-framework-golden-1.1.x
)