Wallaby for Ava
As a testing framework, Ava provides a simple test syntax and a few of useful and powerful features, such as a variety of matchers and snapshot testing. However, as a development time test runner Ava CLI is slow, makes it hard to debug test failures, makes it hard to understand the cause of failing tests, and is distracting. There is an easy way to fix these problems and to become way more productive with Ava
Ava can be slow, even in watch mode.
Ava in watch mode re-runs all tests in all test files related to changed files based on its dependency tracking.
Wallaby only re-runs tests that are affected by your changes, regardless of whether the files are uncommitted, in source control, or unsaved.
If you have 3 source files that are
covered by 3 different test files each, and each test file has 30 or more tests, and you are changing 1 test in one of the test files,
Ava will re-run 30+ tests, on file save event.
If you have changes (saved or not unsaved)
in 3 component files that are
covered by 3 different test files each, with
10 tests each, and are changing 1 test in one of the test files,
Wallaby will re-run 1 test, as you type.
Ava debugging experience is limited, painful to use and outdated.
Wallaby adds a few powerful instruments to debugging classics, designed specifically for tests.
When you need to debug Ava tests, your options are limited to using a good but over a decade old
console.log, or, if your editor supports it and you have correctly configured it, you may
classical debugger. Most of the debugger features are over 40
years old and have not been designed to support a fast edit-and-continue test feedback loop.
When using Wallaby, there's less need to debug in the first place, because of realtime inline
and value explorer. However, when a debugger is required,
addition to existing tools,
time travel debugger and test stories. Wallaby debugger requires no config, works
for monorepos and dynamic/data driven tests, such as
Ava test output is hard to read, search and act upon, especially when many tests are failing.
Wallaby test output is ergonomic, highlighted, editor integrated and actionable.
Ava test output is displayed in the terminal, highlighted with ANSI colors (not from your editor theme) and awkward spacings; limited searching and navigation options makes life hard.
Wallaby test output is deeply integrated with your editor, highlighted using your editor colors and contains actionable links to navigate to tests, logs and errors, view/update snapshots (even for a single test), explore assertion diffs, and debug individual tests.
Ava code coverage is a separately available static artifact of a test run.
Wallaby code coverage is a first class citizen, continuously and seamlessly displayed in editor.
Ava code coverage results are available (via
nyc CLI) as a statically generated HTML
page Istanbul report, and as a
too-high-level-to-be-useful terminal summary report.
Ava is an open source project that is recently maintained mostly by a single person.
Wallaby is a commercially successful tool backed by a team of dedicated professionals passionately working on it full-time for living.
There's no bug you can't fix yourself or question you can't find an answer for, it is just a matter of how you want to spend your time.
Ava is free, but only if your time is free.
Use Wallaby to boost your productivity by running and debugging Ava tests in VS Code or WebStorm as you are writing your tests/code.
Use Ava as your testing framework for your tests, use Ava CLI to run tests as a part of your Continuous Integration (CI) pipeline.