-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(runner): async assertion auto await should timeout #6391
Changes from 6 commits
f48a02c
6722c0a
3e89020
c8e96fd
029edf4
6f68621
ae99539
6b41abd
e18261c
ff8a67b
13ed041
ed3a95b
e7d5597
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -223,16 +223,6 @@ export async function runTest(test: Test | Custom, runner: VitestRunner): Promis | |
} | ||
await fn() | ||
} | ||
// some async expect will be added to this array, in case user forget to await theme | ||
if (test.promises) { | ||
const result = await Promise.allSettled(test.promises) | ||
const errors = result | ||
.map(r => (r.status === 'rejected' ? r.reason : undefined)) | ||
.filter(Boolean) | ||
if (errors.length) { | ||
throw errors | ||
} | ||
Comment on lines
-229
to
-235
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Previously it was waiting for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not really, There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Okay, I copied |
||
} | ||
|
||
await runner.onAfterTryTask?.(test, { | ||
retry: retryCount, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1235,6 +1235,35 @@ Repository: sindresorhus/p-locate | |
|
||
--------------------------------------- | ||
|
||
## package-manager-detector | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This came out when |
||
License: MIT | ||
By: Anthony Fu | ||
Repository: git+https://github.com/antfu-collective/package-manager-detector.git | ||
|
||
> MIT License | ||
> | ||
> Copyright (c) 2020-PRESENT Anthony Fu <https://github.com/antfu> | ||
> | ||
> Permission is hereby granted, free of charge, to any person obtaining a copy | ||
> of this software and associated documentation files (the "Software"), to deal | ||
> in the Software without restriction, including without limitation the rights | ||
> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
> copies of the Software, and to permit persons to whom the Software is | ||
> furnished to do so, subject to the following conditions: | ||
> | ||
> The above copyright notice and this permission notice shall be included in all | ||
> copies or substantial portions of the Software. | ||
> | ||
> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
> SOFTWARE. | ||
|
||
--------------------------------------- | ||
|
||
## picomatch | ||
License: MIT | ||
By: Jon Schlinkert | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure but I needed to add this filter for
fails.test.ts
snapshot sincetest/cli/fixtures/fails/unhandled.test.ts
's stacktrace moved a little and now it points to here