From 30bba102b3c1a9f20964afe577b3b36cd1d541a9 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 30 Apr 2020 09:50:55 +0200 Subject: [PATCH] smoke - only start automatically after data migration tests --- .../areas/workbench/data-migration.test.ts | 2 +- test/smoke/src/main.ts | 51 +++++++++++-------- 2 files changed, 31 insertions(+), 22 deletions(-) diff --git a/test/smoke/src/areas/workbench/data-migration.test.ts b/test/smoke/src/areas/workbench/data-migration.test.ts index 75bd46fee46..8186847be96 100644 --- a/test/smoke/src/areas/workbench/data-migration.test.ts +++ b/test/smoke/src/areas/workbench/data-migration.test.ts @@ -8,7 +8,7 @@ import { join } from 'path'; export function setup(stableCodePath: string, testDataPath: string) { - describe('Data Migration: This test MUST run before releasing by providing the --stable-build command line argument', () => { + describe('Datamigration', () => { it(`verifies opened editors are restored`, async function () { if (!stableCodePath) { this.skip(); diff --git a/test/smoke/src/main.ts b/test/smoke/src/main.ts index caa9913a4da..cb766576d17 100644 --- a/test/smoke/src/main.ts +++ b/test/smoke/src/main.ts @@ -266,16 +266,6 @@ after(async function () { }); describe(`VSCode Smoke Tests (${opts.web ? 'Web' : 'Electron'})`, () => { - before(async function () { - const app = new Application(this.defaultOptions); - await app!.start(opts.web ? false : undefined); - this.app = app; - }); - - after(async function () { - await this.app.stop(); - }); - if (screenshotsPath) { afterEach(async function () { if (this.currentTest.state !== 'failed') { @@ -296,15 +286,34 @@ describe(`VSCode Smoke Tests (${opts.web ? 'Web' : 'Electron'})`, () => { app.logger.log('*** Test start:', title); }); } - if (!opts.web) { setupDataMigrationTests(opts['stable-build'], testDataPath); } - if (!opts.web) { setupDataLossTests(); } - if (!opts.web) { setupDataPreferencesTests(); } - setupDataSearchTests(); - setupDataLanguagesTests(); - setupDataEditorTests(); - setupDataStatusbarTests(!!opts.web); - if (!opts.web) { setupDataExtensionTests(); } - if (!opts.web) { setupDataMultirootTests(); } - if (!opts.web) { setupDataLocalizationTests(); } - if (!opts.web) { setupLaunchTests(); } + + if (!opts.web) { + describe(`Data Migration: This test MUST run before releasing by providing the --stable-build command line argument`, () => { + setupDataMigrationTests(opts['stable-build'], testDataPath); + }); + } + + describe(`VSCode Smoke Tests (${opts.web ? 'Web' : 'Electron'})`, () => { + before(async function () { + const app = new Application(this.defaultOptions); + await app!.start(opts.web ? false : undefined); + this.app = app; + }); + + after(async function () { + await this.app.stop(); + }); + + if (!opts.web) { setupDataLossTests(); } + if (!opts.web) { setupDataPreferencesTests(); } + setupDataSearchTests(); + setupDataLanguagesTests(); + setupDataEditorTests(); + setupDataStatusbarTests(!!opts.web); + if (!opts.web) { setupDataExtensionTests(); } + if (!opts.web) { setupDataMultirootTests(); } + if (!opts.web) { setupDataLocalizationTests(); } + if (!opts.web) { setupLaunchTests(); } + }); }); + -- GitLab