Skip to content

Commit

Permalink
tests: Add back {shell: true} for windows users
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewdotn committed Apr 8, 2021
1 parent 850e0f9 commit e38f6ab
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion libexec/integration-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ const server = startServer(async () => {
if (process.env.OPEN_CYPRESS) {
cypressAction = 'open';
}
const cypressProcess = spawn('npx', ['cypress', cypressAction], {stdio: "inherit"})
const cypressProcess = spawn('npx', ['cypress', cypressAction],
{stdio: "inherit", shell: true})
await new Promise<void>((resolve) => {
cypressProcess.on('close', (code, signal) => {
exitCode = code;
Expand Down
6 changes: 4 additions & 2 deletions libexec/test-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@ export function startServer(onClose: (...args) => unknown): ChildProcess {
throw new Error("dist/test.html not found; do you need to run a build first?")
}

const process = spawn('npx', ['ws', '-p', '8080', '-d', 'dist'], {stdio: "inherit"})
const waitOnProcess = spawn('npx', ['wait-on', 'http-get://localhost:8080/test.html'], {stdio: "inherit"})
const process = spawn('npx', ['ws', '-p', '8080', '-d', 'dist'],
{stdio: "inherit", shell: true})
const waitOnProcess = spawn('npx', ['wait-on', 'http-get://localhost:8080/test.html'],
{stdio: "inherit", shell: true})
waitOnProcess.on('close', onClose)
return process;
}
Expand Down

0 comments on commit e38f6ab

Please sign in to comment.