From 8c85edd08b935639f07a788f3fcac9e6e0b22007 Mon Sep 17 00:00:00 2001 From: Clark Du Date: Fri, 20 Jul 2018 17:23:46 +0100 Subject: [PATCH] test: ignore multiple processes test cases in appveyor --- test/fixtures/cli/cli.build.test.js | 2 +- test/fixtures/cli/cli.gen.test.js | 2 +- test/unit/cli-start.test.js | 2 +- test/unit/cli.test.js | 2 +- test/utils/setup.js | 11 ++++++----- 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/test/fixtures/cli/cli.build.test.js b/test/fixtures/cli/cli.build.test.js index 48c6f9615f..106ac41d58 100644 --- a/test/fixtures/cli/cli.build.test.js +++ b/test/fixtures/cli/cli.build.test.js @@ -6,7 +6,7 @@ const execify = promisify(exec) const rootDir = __dirname const nuxtBin = resolve(__dirname, '..', '..', '..', 'bin', 'nuxt') -describe('cli build', () => { +describe.skip.appveyor('cli build', () => { test('nuxt build', async () => { const { stdout } = await execify(`node ${nuxtBin} build ${rootDir} -c cli.build.config.js`) diff --git a/test/fixtures/cli/cli.gen.test.js b/test/fixtures/cli/cli.gen.test.js index 4e58a1bdc5..4efcedad96 100644 --- a/test/fixtures/cli/cli.gen.test.js +++ b/test/fixtures/cli/cli.gen.test.js @@ -6,7 +6,7 @@ const execify = promisify(exec) const rootDir = __dirname const nuxtBin = resolve(__dirname, '..', '..', '..', 'bin', 'nuxt') -describe('cli generate', () => { +describe.skip.appveyor('cli generate', () => { test('nuxt generate', async () => { const { stdout } = await execify(`node ${nuxtBin} generate ${rootDir} -c cli.gen.config.js`) diff --git a/test/unit/cli-start.test.js b/test/unit/cli-start.test.js index ea8ee96970..a168560cbd 100644 --- a/test/unit/cli-start.test.js +++ b/test/unit/cli-start.test.js @@ -9,7 +9,7 @@ const url = route => 'http://localhost:' + port + route const nuxtBin = resolve(__dirname, '..', '..', 'bin', 'nuxt') -describe('cli', () => { +describe.skip.appveyor('cli', () => { test('nuxt start', async () => { let stdout = '' let error diff --git a/test/unit/cli.test.js b/test/unit/cli.test.js index ea8ee96970..a168560cbd 100644 --- a/test/unit/cli.test.js +++ b/test/unit/cli.test.js @@ -9,7 +9,7 @@ const url = route => 'http://localhost:' + port + route const nuxtBin = resolve(__dirname, '..', '..', 'bin', 'nuxt') -describe('cli', () => { +describe.skip.appveyor('cli', () => { test('nuxt start', async () => { let stdout = '' let error diff --git a/test/utils/setup.js b/test/utils/setup.js index f59e7a3643..dc1ae4ba36 100644 --- a/test/utils/setup.js +++ b/test/utils/setup.js @@ -1,10 +1,11 @@ // eslint-disable require('babel-polyfill') - -const consola = require('consola') +require('consola').clear().add({ + log: jest.fn() +}) jasmine.DEFAULT_TIMEOUT_INTERVAL = 60 * 1000 -consola.clear().add({ - log: jest.fn() -}) +const isAppveyor = !!process.env.APPVEYOR +describe.skip.appveyor = isAppveyor ? describe.skip : describe +test.skip.appveyor = isAppveyor ? test.skip : test