Based on discussion with @tommy-mitchell in #3224:
test.failing('does foo', t => {
// ..
}).because('waiting on some/repo#123')
Should output:
✔ [expected fail] does foo
- waiting on some/repo#123
This requires changes to https://github.com/avajs/ava/blob/main/lib/create-chain.js so that a chainable object is returned for test.failing(), test.skip() etc. Here we then need to add a because function. The reason should make its way to the reporter where it can be printed beneath the test title.
This should be reflected in the type definitions and documentation. Once we've made some progress on this, work needs to be done with https://github.com/avajs/eslint-plugin-ava to support this new modifier.
It should be a test failure if because() is called with anything but a non-empty string.
Based on discussion with @tommy-mitchell in #3224:
Should output:
This requires changes to https://github.com/avajs/ava/blob/main/lib/create-chain.js so that a chainable object is returned for
test.failing(),test.skip()etc. Here we then need to add abecausefunction. The reason should make its way to the reporter where it can be printed beneath the test title.This should be reflected in the type definitions and documentation. Once we've made some progress on this, work needs to be done with https://github.com/avajs/eslint-plugin-ava to support this new modifier.
It should be a test failure if
because()is called with anything but a non-empty string.