Skip to content
Myr

Fix test flakiness on Windows

Before adoption: this commit came in with the history the project adopted, so no landing records it.

💩

authored by Sindre Sorhus · committed by Sindre Sorhus · parent b4d1c86 · Browse files · 3 files+5 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+5 added−3 removed

  • other:+5 added−3 removed

3 files+5 added−3 removed

modified:.travis.yml+2 added
modified:appveyor.yml+1 added-1 removed
modified:test.js+2 added-2 removed
127 unmodified lines
128 await t.throws(m('cat-names', {preferLocal: false}), /spawn .* ENOENT/);129 process.env.PATH = _path;130});131132test('localDir option', async t => {132test.serial('localDir option', async t => {133 const cwd = 'fixtures/local-dir';134 const bin = path.resolve(cwd, 'node_modules/.bin/self-path');135136 await m('npm', ['install', '--no-package-lock'], {cwd});
193 unmodified lines
330 t.not(err.code, 22);331});332333test('timeout will not kill the process early', async t => {334 const err = await t.throws(m('delay', ['3000', '22'], {timeout: 9000}));334 const err = await t.throws(m('delay', ['3000', '22'], {timeout: 30000}));335336 t.false(err.timedOut);337 t.is(err.code, 22);338});
112 unmodified lines