Closed greenkeeper[bot] closed 5 years ago
After pinning to 2.2.0 your tests are passing again. Downgrade this dependency π.
devDependency
ava was updated from 2.3.0
to 2.4.0
.Your tests are passing again with this update. Explicitly upgrade to this version π
t.try()
assertionsThanks to the amazing work and patience of @qlonik we're shipping a new assertion! t.try()
lets you perform assertions and decide whether to commit or discard their outcome. All kinds of interesting things can be built on top of this, from fuzzy testers to new test interfaces and more.
We're excited to get this out there, but it's not quite done yet. For now you have to opt in to this new feature. Being opt-in, we may make changes (breaking ones even!) until we feel this is stable.
To opt in, configure AVA with the following:
package.json
:
{
"ava": {
"nonSemVerExperiments": {
"tryAssertion": true
}
}
}
ava.config.js
:
export default {
nonSemVerExperiments: {
tryAssertion: true
}
};
We'd love to hear your feedback. Please join us in this issue: #2250
Also, if you're looking to help out with the remaining issues so that we can ship this without the opt-in, have a look at this project: https://github.com/orgs/avajs/projects/1
Thanks again @qlonik!
Thank you @jeremenichelli, @jamesgeorge007, @dongjae93, @qlonik and @tryzniak. We couldn't have done this without you!
We welcome new contributors. AVA is a friendly place to get started in open source. We have a great article on getting started contributing and a comprehensive contributing guide.
The new version differs by 14 commits.
05f077e
2.4.0
ca4eff7
Bump dependencies
67e4dea
Update endpoint testing recipe to focus on the concept, not libraries
4fdb02d
Implement experimental t.try() assertion
782c2d8
Run some tests on Travis still
4c890d9
Add OpenCollective link to README
03c1509
Groundwork to support experimental features
0a5c933
Remove unnecessary flag from tap invocation
e598c30
Detect whether error source is on a different drive (on Windows)
fb0c536
Fix serialize-error tests on Windows with GitHub Actions
53d7fe1
Allow some fixtures to pass linting when XO is installed without lockfile
11771ba
Run CI using GitHub Actions
5538bdc
Replace an indexOf() by includes()
49b202f
Add shared variables & asynchronous tests to common pitfalls
See the full diff
devDependency
ava was updated from 3.3.0
to 3.4.0
.Your tests are still failing with this version. Compare changes
t.try()
assertionThe new t.try()
allows you to try assertions without causing the test to fail:
test('do the thing', async t => {
const attempt = () => t.try(tt => {
const result = await getResult()
// getResult() can be flaky and sometimes throws :(
tt.is(result, 'expected')
})
const firstAttempt = await attempt()
if (firstAttempt.passed) return firstAttempt.commit()
t.log('Retrying (just once)')
firstAttempt.discard()
const secondAttempt = await attempt()
secondAttempt.commit()
})
You can use any test implementation with t.try()
, including (arrays of) macros. You can decide what to do with attempts. You can even run attempts concurrently, so long as they don't use snapshot assertions.
This is great building block for handling all kinds of advanced test scenarios. We can't wait to see what you'll do with it! Find out more in the assertion documentation.
This feature was previously behind an experimental flag. That flag has now been removed. If you have enabled the flag you'll have to update your AVA config. Also note that as of this release, attempt titles are always prefixed with the title of the parent test 7ee3a0e.
Once again, thank you @qlonik for contributing this new assertion.
t.throws()
and t.throwsAsync()
assertions can now be called with undefined
as the second argument. Previously, if you wanted to set an assertion message but did not want to provide any expectations for the thrown error you had to pass null
. That's still allowed, of course. d0e2161 @stavalfiava.config.js
files once again work with our @ava/typescript
package f4d4edd@types/node
7a1dacftest.cb()
is used with asynchronous functions or observables f5a8c2b @toddkcarlsonjsdom-global
instead of browser-env
3f9c616 @ScrumSee v3.3.0...v3.4.0 for all changes.
The new version differs by 123 commits.
8630636
3.4.0
12ba7bc
Ship t.try() without requiring opt-in
f4d4edd
Evaluate ava.config.js scripts in current context
8831f54
Improve detection of ESM support
d0e2161
Support undefined as second argument to t.throws and t.throwsAsync
324e45f
Document t.try()
(#2251)
da52e5f
Bump dependencies
55a3649
Ensure t.try() assigns unique titles when multiple implementations are passed
7ee3a0e
Prefix attempt titles with that of parent test
a69e4f2
Bump dependencies
7a1dacf
Remove @types/node reference
3f9c616
Update Vue recipe to use JSDom rather than browser-env
f5a8c2b
Improve error message when test.cb()
is used with promises
c166e05
3.3.0
362b6f9
Upgrade @ava/babel
There are 123 commits in total.
See the full diff
devDependency
ava was updated from 3.4.0
to 3.5.0
.Your tests are still failing with this version. Compare changes
When using ava debug
, you can now specify the address or hostname the inspector is available through by using the --host
option. Thanks to @DYefimov for contributing this! 13d6651
See v3.4.0...v3.5.0 for all changes. Spoiler alert: it's just this one
devDependency
ava was updated from 3.5.0
to 3.5.1
.Your tests are still failing with this version. Compare changes
devDependency
ava was updated from 3.5.2
to 3.6.0
.Your tests are still failing with this version. Compare changes
afterEach()
and afterEach.always()
hooks can now determine whether the test passed. Thank you @bunysae for contributing this! 8f312c0:
test('passes', t => t.pass());
test.afterEach(t => {
if (t.passed) {
// Do something because the test passed
} else {
// Do something because the test failed
}
});
@mbiesiad has diligently translated our documentation to Polish. Thank you @kekuu for reviewing.
Also thank you @timgates42 for fixing a typo in our documentation. ede4f32
See v3.5.0...v3.6.0 for all changes.
The new version differs by 7 commits.
447d371
3.6.0
886b4d7
Rebuild lockfile
1f59b05
Dependency updates
489b13e
Fix TypeScript documentation for t.try()
4bf64d0
Remove link to previously removed recipe
8f312c0
Add t.passed to execution contexts
ede4f32
Fix typo in endpoint testing recipe
See the full diff
devDependency
ava was updated from 3.6.0
to 3.7.0
.Your tests are still failing with this version. Compare changes
If you've ever wanted to save some files along with AVA's snapshots, you can now determine the directory path by accessing test.meta.snapshotDirectory
. Thank you @ulken ! cb5f9f7
See v3.6.0...v3.7.0 for all changes.
devDependency
ava was updated from 3.7.1
to 3.8.0
.Your tests are passing again with this update. Explicitly upgrade to this version π
Great news, this is a feature heavy release!
First off, though, AVA now officially supports Node.js 14. Thank you @zackschuster! 2e7c76b
AVA can now run tests at specific line numbers!
Given the following test file:
test.js
1: test('unicorn', t => {
2: t.pass();
3: });
4:
5: test('rainbow', t => {
6: t.fail();
7: });
Running npx ava test.js:2
for would run the unicorn
test. In fact you could use any line number between 1
and 3
.
This feature is only available from the command line. It won't work if you use tools like ts-node/register
or @babel/register
, and it does not currently work with @ava/babel
and @ava/typescript
. See #2473.
Thank you @ulken for your hard work and patience to get this shipped. 1222ce9
Sometimes tests have side-effects you want to clean up. @ulken has implemented t.teardown()
which lets you register teardown functions within your test. They'll run once your test has finished, even if it failed: 75cbc3b
test('read file', t => {
fs.writeFileSync('file.txt', 'π');
t.teardown(() => fs.unlinkSync('file.txt');
// Run assertions
});
Thanks to @bunysae, stack traces now include Node.js internals. Previously we removed them because we wanted you to focus on your own code, but quite often they do provide context. Now they're displayed, but somewhat dimmed. 9a9351d
Watch mode with the default reporter once again accepts key input. Thanks @pcdevil! 59c227d
See v3.7.1...v3.8.0 for all changes.
The new version differs by 13 commits.
b669efa
3.8.0
0976cfe
Dependency updates
1222ce9
Run tests at selected line numbers
75cbc3b
Add t.teardown()
993bb90
Remove test slowness output checks from reporter tests
af7b2d5
Don't print empty error stacks
2e7c76b
Node.js 14 compatibility
59c227d
Fix watch mode with mini reporter
9a9351d
Retain (most of) Node.js internals in stack traces
3c0fc03
3.7.1
26c8326
Support parallel runs that do not need to run test files
7eb23dd
Remove now unnecessary finishPromised()
from lib/test.js
276c16a
Use HTTPS links
See the full diff
devDependency
ava was updated from 3.8.0
to 3.8.1
.Your tests are passing again with this update. Explicitly upgrade to this version π
Great news, this is a feature heavy release!
First off, though, AVA now officially supports Node.js 14. Thank you @zackschuster! 2e7c76b
AVA can now run tests at specific line numbers!
Given the following test file:
test.js
1: test('unicorn', t => {
2: t.pass();
3: });
4:
5: test('rainbow', t => {
6: t.fail();
7: });
Running npx ava test.js:2
for would run the unicorn
test. In fact you could use any line number between 1
and 3
.
This feature is only available from the command line. It won't work if you use tools like ts-node/register
or @babel/register
, and it does not currently work with @ava/babel
and @ava/typescript
. See #2473.
Thank you @ulken for your hard work and patience to get this shipped. 1222ce9
Sometimes tests have side-effects you want to clean up. @ulken has implemented t.teardown()
which lets you register teardown functions within your test. They'll run once your test has finished, even if it failed: 75cbc3b
test('read file', t => {
fs.writeFileSync('file.txt', 'π');
t.teardown(() => fs.unlinkSync('file.txt');
// Run assertions
});
Thanks to @bunysae, stack traces now include Node.js internals. Previously we removed them because we wanted you to focus on your own code, but quite often they do provide context. Now they're displayed, but somewhat dimmed. 9a9351d
Watch mode with the default reporter once again accepts key input. Thanks @pcdevil! 59c227d
afterEach()
and afterEach.always()
hooks can now determine whether the test passed. Thank you @bunysae for contributing this! 8f312c0
test('passes', t => t.pass());
test.afterEach(t => {
if (t.passed) {
// Do something because the test passed
} else {
// Do something because the test failed
}
});
If you've ever wanted to save some files along with AVA's snapshots, you can now determine the directory path by accessing test.meta.snapshotDirectory
. Thank you @ulken! cb5f9f7
See v3.7.1...v3.8.1 for all changes.
The new version differs by 16 commits.
7df4397
3.8.1
63ea26c
Upgrade matcher
a9c165f
Tweak codecov uploads
b669efa
3.8.0
0976cfe
Dependency updates
1222ce9
Run tests at selected line numbers
75cbc3b
Add t.teardown()
993bb90
Remove test slowness output checks from reporter tests
af7b2d5
Don't print empty error stacks
2e7c76b
Node.js 14 compatibility
59c227d
Fix watch mode with mini reporter
9a9351d
Retain (most of) Node.js internals in stack traces
3c0fc03
3.7.1
26c8326
Support parallel runs that do not need to run test files
7eb23dd
Remove now unnecessary finishPromised()
from lib/test.js
There are 16 commits in total.
See the full diff
devDependency
ava was updated from 3.8.1
to 3.8.2
.Your tests are passing again with this update. Explicitly upgrade to this version π
The new version differs by 22 commits.
dace976
3.8.2
05c3158
Prep for release
fd92b4a
Correctly use picomatch dependency
bec7c9e
Configure import/no-unresolved linter rule
c8f31a3
Test AVA using AVA
a5385a4
Use configured depth limit for diffs in assertion failures
7df4397
3.8.1
63ea26c
Upgrade matcher
a9c165f
Tweak codecov uploads
b669efa
3.8.0
0976cfe
Dependency updates
1222ce9
Run tests at selected line numbers
75cbc3b
Add t.teardown()
993bb90
Remove test slowness output checks from reporter tests
af7b2d5
Don't print empty error stacks
There are 22 commits in total.
See the full diff
The devDependency ava was updated from
2.2.0
to2.3.0
.π¨ View failing branch.
This version is covered by your current version range and after updating it in your project the build failed.
ava is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.
Status Details
- β **continuous-integration/travis-ci/push:** The Travis CI build failed ([Details](https://travis-ci.org/k0nsti/konsum/builds/573400128?utm_source=github_status&utm_medium=notification)). - β **coverage/coveralls:** First build on greenkeeper/ava-2.3.0 at 35.958% ([Details](https://coveralls.io/builds/25197167)).Release Notes for 2.3.0
Changes
import-local@^3.0.2
which fixes issues with Lerna projects.t.context
tounknown
, in line with TypeScript's changes in their 3.5 release. 2fc7d56All changes
v2.2.0...v2.3.0
Thanks
Thank you @MarchWorks, @yovasx2 and @bobthekingofegypt. We couldn't have done this without you!
Get involved
We welcome new contributors. AVA is a friendly place to get started in open source. We have a great article on getting started contributing and a comprehensive contributing guide.
Commits
The new version differs by 10 commits.
1c81c4b
2.3.0
9e8d28f
Watcher: Only track test files has having exclusive tests if at least one test was selected
7dcb473
Update fake-tty for changes in Node.js 12.7.0
9baca8c
Enable V8 supported stage-3 syntax, as well as stage-4 syntax
7fb0546
Bump dependencies
ffa62ce
Consistent paths in watcher
b27cb8d
Print internal errors when precompiler setup or globbing fails
8628976
Print hooks and remaining tests as TAP comments
f01d05f
Ensure CLI receives file paths
2fc7d56
Change default Context type to unknown
See the full diff
FAQ and help
There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those donβt help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).Your Greenkeeper Bot :palm_tree: