Commit 46ffecdfff56 added testament-based unit testing, but didn't migrate the fd_cache tests because they relied on files to be manually created. On main, we would see the error:
$ nim r src/fd_cache.nim
fatal.nim(53) sysFatal
Error: unhandled exception: fd_cache.nim(272, 11) `one1 != two` [AssertionDefect]
Make those tests self-contained, and migrate them to the new testament-based system so they now run in CI.
A new import syntax import foo {.all.} now allows importing all symbols (public or private) from foo. This can be useful for testing purposes or for more flexibility in project organization.
Commit 46ffecdfff56 added testament-based unit testing, but didn't migrate the fd_cache tests because they relied on files to be manually created. On
main
, we would see the error:Make those tests self-contained, and migrate them to the new testament-based system so they now run in CI.
Also prefer
doAssert
as Nim itself recommends, and use{.all.}
to avoid adding the export marker in source files only for testing purposes. From the Nim 1.6.0 release post:Closes: https://github.com/crashappsec/chalk/issues/275