]> git.ipfire.org Git - thirdparty/vuejs/create-vue.git/commitdiff
test: enable `shell` option, fixing pnpm ENOENT errors
authorHaoqun Jiang <haoqunjiang@gmail.com>
Mon, 23 Aug 2021 11:54:24 +0000 (19:54 +0800)
committerHaoqun Jiang <haoqunjiang@gmail.com>
Mon, 23 Aug 2021 11:54:24 +0000 (19:54 +0800)
test.js

diff --git a/test.js b/test.js
index 785ad715963d9d7b670f096a0564b92b0fda1ce5..6746a2f8d1d6698a83b58917f69aab899caae4e8 100644 (file)
--- a/test.js
+++ b/test.js
@@ -14,7 +14,8 @@ for (const projectName of fs.readdirSync(playgroundDir)) {
     console.log(`Running unit tests in ${projectName}`)
     const unitTestResult = spawnSync('pnpm', ['test:unit:ci'], {
       cwd: path.resolve(playgroundDir, projectName),
-      stdio: 'inherit'
+      stdio: 'inherit',
+      shell: true
     })
     if (unitTestResult.status !== 0) {
       throw new Error(`Unit tests failed in ${projectName}`)
@@ -23,7 +24,8 @@ for (const projectName of fs.readdirSync(playgroundDir)) {
     console.log(`Running e2e tests in ${projectName}`)
     const e2eTestResult = spawnSync('pnpm', ['test:e2e:ci'], {
       cwd: path.resolve(playgroundDir, projectName),
-      stdio: 'inherit'
+      stdio: 'inherit',
+      shell: true
     })
     if (e2eTestResult.status !== 0) {
       throw new Error(`E2E tests failed in ${projectName}`)