Skip to content

Commit

Permalink
tests ~ replace and increase 'ava' global test timeout
Browse files Browse the repository at this point in the history
- use global timeout instead of individual test timeouts

# Discussion

Individual test timeouts (`t.timeout(...)`) do *not* increase the global timeout; they
only decrease the timeout. So, they are currently worthless for modifying longer tests.

* ref: <avajs/ava#2384>
  • Loading branch information
rivy committed Feb 9, 2021
1 parent 178da83 commit 96cd446
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@
"files": [
"!**/*.test-d.ts"
],
"timeout": "60s",
"typescript": {
"rewritePaths": {
"src/": "build/cjs+tests/"
Expand Down
6 changes: 3 additions & 3 deletions test/integration.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ if (process.env.npm_config_test_for_dist) {
});
} else {
test('examples are executable without error (Deno)', (t) => {
t.timeout(30000); // 30s timeout
// t.timeout(30000); // 30s timeout

const egDirPath = 'eg';
const extension_regexps = [/.*[.]deno[.]ts$/i];
Expand Down Expand Up @@ -75,7 +75,7 @@ if (process.env.npm_config_test_for_dist) {
}

test('examples are executable without error (JavaScript)', (t) => {
t.timeout(30000); // 30s timeout
// t.timeout(30000); // 30s timeout

const egDirPath = 'eg';
const extensions = ['.js', '.cjs', '.mjs'];
Expand Down Expand Up @@ -106,7 +106,7 @@ if (process.env.npm_config_test_for_dist) {
});

test('examples are executable without error (TypeScript)', (t) => {
t.timeout(30000); // 30s timeout
// t.timeout(30000); // 30s timeout

const egDirPath = 'eg';
const extensions = ['.js', '.cjs', '.mjs', '.ts'];
Expand Down

0 comments on commit 96cd446

Please sign in to comment.