ava
8.4.0 · 7 Nov 2026MIT575.3k / weekRepositoryHomepagenpmAtom feed
0.25.0 is the newest release of 0.17.x.
In short
1 removed1 deprecated12 new1 internal
- Removed
Removed the
--requireCLI flag. Configure it in package.json instead. 17119bc - Deprecated
Deprecated
t.error()alias fort.ifError(). It will be removed in AVA 1.0.0. Just uset.ifError(). 28bb0d5 (We have an automatic migration script if you're usingt.error())
Release note
The current working directory in test files changed (BREAKING)
We made the hard decision of changing the current working directory (process.cwd()) in test files to be the same directory as package.json. It was previously the same as __dirname (the directory of the test file). Having process.cwd() equal __dirname felt like a good idea at the time, but as the popularity of AVA grew, people started hitting issues with it.
This affects users that have test files in a sub-folder and are using relative paths. If you have your test files in the same directory as package.json, you're fine.
The fix is to wrap all relative paths in path.join(__dirname, 'relative-path') to make them absolute.
Here's an example of what needs changing. The below file and unicorn.txt are both in ./test/.
-t.true(fs.existsSync('unicorn.txt'));
+t.true(fs.existsSync(path.join(__dirname, 'unicorn.txt')));Let us know if anything is unclear or if you're having problems.
Commit: 476c653
Node.js version support
The next minor version of AVA, 0.18.0, will drop support for Node.js v0.10 and v0.12. We'll continue fixing critical issues for this version until the end of the year. Time to upgrade if you haven't. (Discussion: #1051)
Highlights
We now have a script to automatically migrate from tape to AVA.
Our ESLint plugin received two new rules:
Reduced transpilation on Node.js >=4. AVA now only transpiles what's needed for Node.js 4 when on it or higher, which should result in better performance and stacktraces. 4025d81
- Removed
Removed the
--requireCLI flag. Configure it in package.json instead. 17119bc Switched to
lodash.isEqualfor deep equality checking (t.deepEqual()&t.notDeepEqual()). This might make your test fail if our previous deep equality check was too loose. 8856684Improvements to the test failure output. e4f90e0 (We're currently working on many more improvements in this area. Stay tuned.)
Added option to disable
power-assert. 24a38acCorrectly clean up stacktraces on Node.js 6 and higher. 26bcab0
Removed
t.doesNotThrow()as it was renamed tot.notThrows(). It was deprecated far back in AVA 0.12.0. e448798- Deprecated
Deprecated
t.error()alias fort.ifError(). It will be removed in AVA 1.0.0. Just uset.ifError(). 28bb0d5 (We have an automatic migration script if you're usingt.error()) Ensures test files load correct AVA installation. This means you can now run AVA with an absolute path and it will still use the local AVA installation at that path if available. 3ea2ba1
Added support for debugging tests with WebStorm and added a recipe. c268c8d
Improvements to the TypeScript type definition. 4baa170 8816faf c40477a
We started exploring browser support. 204f2be
All Changes
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.