From 33dc8e6cfd66e4885e6a4d974ca9bef7301bf9ee Mon Sep 17 00:00:00 2001 From: spalger Date: Mon, 11 Mar 2019 22:02:38 -0700 Subject: [PATCH] [x-pack/jest/integration] Jest runs setup hook when tests are skipped... --- test/scripts/jenkins_xpack.sh | 10 +++++----- x-pack/scripts/jest_integration.js | 7 +++++++ .../jest/integration_tests/example_integration.test.ts | 3 +-- 3 files changed, 13 insertions(+), 7 deletions(-) diff --git a/test/scripts/jenkins_xpack.sh b/test/scripts/jenkins_xpack.sh index beec60ba15ea..db2b47e6c8ff 100755 --- a/test/scripts/jenkins_xpack.sh +++ b/test/scripts/jenkins_xpack.sh @@ -30,8 +30,8 @@ node scripts/jest --ci --no-cache --verbose echo "" echo "" -echo " -> Running jest integration tests" -cd "$XPACK_DIR" -node scripts/jest_integration --ci --no-cache --verbose -echo "" -echo "" +# echo " -> Running jest integration tests" +# cd "$XPACK_DIR" +# node scripts/jest_integration --ci --no-cache --verbose +# echo "" +# echo "" diff --git a/x-pack/scripts/jest_integration.js b/x-pack/scripts/jest_integration.js index 8311a9d283cb..dd0af087b331 100644 --- a/x-pack/scripts/jest_integration.js +++ b/x-pack/scripts/jest_integration.js @@ -16,6 +16,13 @@ // // See all cli options in https://facebook.github.io/jest/docs/cli.html +throw new Error(` + jest_integration tests have been disabled because of a flaky failure in the + example integration test: https://github.com/elastic/kibana/issues/32795#issuecomment-471585274 + + when un-skipping these tests make sure to uncomment test/scripts/jenkins_xpack.sh lines 33-37 +`); + const resolve = require('path').resolve; process.argv.push('--config', resolve(__dirname, '../test_utils/jest/config.integration.js')); process.argv.push('--runInBand'); diff --git a/x-pack/test_utils/jest/integration_tests/example_integration.test.ts b/x-pack/test_utils/jest/integration_tests/example_integration.test.ts index d1761bb64974..dd8890299f6e 100644 --- a/x-pack/test_utils/jest/integration_tests/example_integration.test.ts +++ b/x-pack/test_utils/jest/integration_tests/example_integration.test.ts @@ -21,8 +21,7 @@ describe('example integration test with kbn server', async () => { await servers.stop(); }); - // FLAKY: https://github.com/elastic/kibana/issues/32795#issuecomment-471585274 - it.skip('should have started new platform server correctly', () => { + it('should have started new platform server correctly', () => { expect(servers.kbnServer).toBeDefined(); expect(servers.kbnServer.server).toBeDefined(); expect(servers.kbnServer.server.plugins).toBeDefined();