diff --git a/package.json b/package.json index 7258b74b680..5a7ab5e9d05 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "watch-extensions": "node --max_old_space_size=4095 ./node_modules/gulp/bin/gulp.js watch-extensions watch-extension-media", "watch-extensionsd": "deemon yarn watch-extensions", "kill-watch-extensionsd": "deemon --kill yarn watch-extensions", - "mocha": "mocha test/unit/node/all.js --delay", + "mocha": "mocha test/unit/node/all.js --delay --ui=tdd", "precommit": "node build/hygiene.js", "gulp": "node --max_old_space_size=8192 ./node_modules/gulp/bin/gulp.js", "electron": "node build/lib/electron", diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/test/notebookClipboard.test.ts b/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/test/notebookClipboard.test.ts index e9389a15c51..ec7ccff62da 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/test/notebookClipboard.test.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/clipboard/test/notebookClipboard.test.ts @@ -7,7 +7,7 @@ import * as assert from 'assert'; import { mock } from 'vs/base/test/common/mock'; import { NotebookClipboardContribution, runCopyCells, runCutCells } from 'vs/workbench/contrib/notebook/browser/contrib/clipboard/notebookClipboard'; import { CellKind, SelectionStateType } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { IEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IActiveNotebookEditor, INotebookEditor, NOTEBOOK_EDITOR_ID } from 'vs/workbench/contrib/notebook/browser/notebookBrowser'; import { IVisibleEditorPane } from 'vs/workbench/common/editor'; diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/find/test/find.test.ts b/src/vs/workbench/contrib/notebook/browser/contrib/find/test/find.test.ts index a933d0dc3eb..6aac1a92f6b 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/find/test/find.test.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/find/test/find.test.ts @@ -15,7 +15,7 @@ import { FindModel } from 'vs/workbench/contrib/notebook/browser/contrib/find/fi import { IActiveNotebookEditor } from 'vs/workbench/contrib/notebook/browser/notebookBrowser'; import { ICellModelDecorations, ICellModelDeltaDecorations, NotebookViewModel } from 'vs/workbench/contrib/notebook/browser/viewModel/notebookViewModel'; import { CellEditType, CellKind } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('Notebook Find', () => { const configurationValue: IConfigurationValue = { diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/fold/test/notebookFolding.test.ts b/src/vs/workbench/contrib/notebook/browser/contrib/fold/test/notebookFolding.test.ts index e547d028d10..e75d9569a72 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/fold/test/notebookFolding.test.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/fold/test/notebookFolding.test.ts @@ -5,7 +5,7 @@ import * as assert from 'assert'; import { CellKind } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { IUndoRedoService } from 'vs/platform/undoRedo/common/undoRedo'; import { FoldingModel, updateFoldingStateAtIndex } from 'vs/workbench/contrib/notebook/browser/contrib/fold/foldingModel'; import { DisposableStore } from 'vs/base/common/lifecycle'; diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/outline/test/notebookOutline.test.ts b/src/vs/workbench/contrib/notebook/browser/contrib/outline/test/notebookOutline.test.ts index bdb7bbf450d..3a543fd6a4a 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/outline/test/notebookOutline.test.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/outline/test/notebookOutline.test.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as assert from 'assert'; -import { setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { OutlineTarget } from 'vs/workbench/services/outline/browser/outline'; import { NotebookCellOutline } from 'vs/workbench/contrib/notebook/browser/contrib/outline/notebookOutline'; import { IFileIconTheme, IThemeService } from 'vs/platform/theme/common/themeService'; diff --git a/src/vs/workbench/contrib/notebook/browser/contrib/undoRedo/test/notebookUndoRedo.test.ts b/src/vs/workbench/contrib/notebook/browser/contrib/undoRedo/test/notebookUndoRedo.test.ts index 0485436e363..92e75527577 100644 --- a/src/vs/workbench/contrib/notebook/browser/contrib/undoRedo/test/notebookUndoRedo.test.ts +++ b/src/vs/workbench/contrib/notebook/browser/contrib/undoRedo/test/notebookUndoRedo.test.ts @@ -6,7 +6,7 @@ import * as assert from 'assert'; import { IModeService } from 'vs/editor/common/services/modeService'; import { CellEditType, CellKind } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('Notebook Undo/Redo', () => { test('Basics', async function () { diff --git a/src/vs/workbench/contrib/notebook/test/cellOperations.test.ts b/src/vs/workbench/contrib/notebook/test/browser/cellOperations.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/cellOperations.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/cellOperations.test.ts index 54408f05cef..4a33e544ebc 100644 --- a/src/vs/workbench/contrib/notebook/test/cellOperations.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/cellOperations.test.ts @@ -7,7 +7,7 @@ import * as assert from 'assert'; import { FoldingModel, updateFoldingStateAtIndex } from 'vs/workbench/contrib/notebook/browser/contrib/fold/foldingModel'; import { changeCellToKind, computeCellLinesContents, copyCellRange, joinNotebookCells, moveCellRange, moveCellToIdx, runDeleteAction } from 'vs/workbench/contrib/notebook/browser/controller/cellOperations'; import { CellEditType, CellKind, SelectionStateType } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { Range } from 'vs/editor/common/core/range'; import { ResourceTextEdit } from 'vs/editor/browser/services/bulkEditService'; import { ResourceNotebookCellEdit } from 'vs/workbench/contrib/bulkEdit/browser/bulkCellEdits'; diff --git a/src/vs/workbench/contrib/notebook/test/cellOutput.test.ts b/src/vs/workbench/contrib/notebook/test/browser/cellOutput.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/cellOutput.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/cellOutput.test.ts index 5354a020e95..74cf4cb743d 100644 --- a/src/vs/workbench/contrib/notebook/test/cellOutput.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/cellOutput.test.ts @@ -21,7 +21,7 @@ import { CodeCellViewModel } from 'vs/workbench/contrib/notebook/browser/viewMod import { NotebookTextModel } from 'vs/workbench/contrib/notebook/common/model/notebookTextModel'; import { BUILTIN_RENDERER_ID, CellEditType, CellKind, IOutputDto, IOutputItemDto } from 'vs/workbench/contrib/notebook/common/notebookCommon'; import { INotebookService } from 'vs/workbench/contrib/notebook/common/notebookService'; -import { setupInstantiationService, valueBytesFromString, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, valueBytesFromString, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; OutputRendererRegistry.registerOutputTransform(class implements IOutputTransformContribution { getType() { return RenderOutputType.Mainframe; } diff --git a/src/vs/workbench/contrib/notebook/test/notebookBrowser.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookBrowser.test.ts similarity index 100% rename from src/vs/workbench/contrib/notebook/test/notebookBrowser.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookBrowser.test.ts diff --git a/src/vs/workbench/contrib/notebook/test/notebookCellList.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookCellList.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookCellList.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookCellList.test.ts index d4ab41123b4..0e0af31e62c 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookCellList.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookCellList.test.ts @@ -9,7 +9,7 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { CellKind } from 'vs/workbench/contrib/notebook/common/notebookCommon'; import { NotebookOptions } from 'vs/workbench/contrib/notebook/common/notebookOptions'; -import { createNotebookCellList, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { createNotebookCellList, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookCellList', () => { let disposables: DisposableStore; diff --git a/src/vs/workbench/contrib/notebook/test/notebookCommon.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookCommon.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookCommon.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookCommon.test.ts index df25485acaa..f947237b079 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookCommon.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookCommon.test.ts @@ -11,7 +11,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { CellKind, CellUri, diff, MimeTypeDisplayOrder, NotebookWorkingCopyTypeIdentifier } from 'vs/workbench/contrib/notebook/common/notebookCommon'; import { cellIndexesToRanges, cellRangesToIndexes, reduceCellRanges } from 'vs/workbench/contrib/notebook/common/notebookRange'; -import { setupInstantiationService, TestCell } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, TestCell } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookCommon', () => { let disposables: DisposableStore; diff --git a/src/vs/workbench/contrib/notebook/test/notebookDiff.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookDiff.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookDiff.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookDiff.test.ts index cab9ddc108d..9103ade7a2b 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookDiff.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookDiff.test.ts @@ -11,7 +11,7 @@ import { TestConfigurationService } from 'vs/platform/configuration/test/common/ import { NotebookDiffEditorEventDispatcher } from 'vs/workbench/contrib/notebook/browser/diff/eventDispatcher'; import { NotebookTextDiffEditor } from 'vs/workbench/contrib/notebook/browser/diff/notebookTextDiffEditor'; import { CellKind, CellSequence } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { withTestNotebookDiffModel } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { withTestNotebookDiffModel } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookCommon', () => { const configurationService = new TestConfigurationService(); diff --git a/src/vs/workbench/contrib/notebook/test/notebookEditor.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookEditor.test.ts similarity index 98% rename from src/vs/workbench/contrib/notebook/test/notebookEditor.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookEditor.test.ts index 928180928d9..d4bba199a35 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookEditor.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookEditor.test.ts @@ -11,7 +11,7 @@ import { FoldingModel, updateFoldingStateAtIndex } from 'vs/workbench/contrib/no import { expandCellRangesWithHiddenCells, INotebookEditor } from 'vs/workbench/contrib/notebook/browser/notebookBrowser'; import { ListViewInfoAccessor } from 'vs/workbench/contrib/notebook/browser/notebookEditorWidget'; import { CellKind } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { createNotebookCellList, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { createNotebookCellList, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('ListViewInfoAccessor', () => { let disposables: DisposableStore; diff --git a/src/vs/workbench/contrib/notebook/test/notebookEditorKernelManager.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookEditorKernelManager.test.ts similarity index 98% rename from src/vs/workbench/contrib/notebook/test/notebookEditorKernelManager.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookEditorKernelManager.test.ts index 87b6f0ffaa3..bb337ccced1 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookEditorKernelManager.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookEditorKernelManager.test.ts @@ -12,7 +12,7 @@ import { NotebookEditorKernelManager } from 'vs/workbench/contrib/notebook/brows import { NotebookViewModel } from 'vs/workbench/contrib/notebook/browser/viewModel/notebookViewModel'; import { NotebookTextModel } from 'vs/workbench/contrib/notebook/common/model/notebookTextModel'; import { CellKind, IOutputDto, NotebookCellMetadata } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { setupInstantiationService, withTestNotebook as _withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, withTestNotebook as _withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { Event } from 'vs/base/common/event'; import { ISelectedNotebooksChangeEvent, INotebookKernelService, INotebookKernel } from 'vs/workbench/contrib/notebook/common/notebookKernelService'; import { NotebookKernelService } from 'vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl'; diff --git a/src/vs/workbench/contrib/notebook/test/notebookEditorModel.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookEditorModel.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookEditorModel.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookEditorModel.test.ts index 08fc7861a57..d71a25076b3 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookEditorModel.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookEditorModel.test.ts @@ -22,7 +22,7 @@ import { IWorkingCopyService } from 'vs/workbench/services/workingCopy/common/wo import { IWorkingCopy } from 'vs/workbench/services/workingCopy/common/workingCopy'; import { NotebookTextModel } from 'vs/workbench/contrib/notebook/common/model/notebookTextModel'; import { CellKind, NotebookData, TransientOptions } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { setupInstantiationService } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { VSBuffer } from 'vs/base/common/buffer'; import { CancellationToken } from 'vs/base/common/cancellation'; import { Mimes } from 'vs/base/common/mime'; diff --git a/src/vs/workbench/contrib/notebook/test/notebookKernelService.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookKernelService.test.ts similarity index 98% rename from src/vs/workbench/contrib/notebook/test/notebookKernelService.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookKernelService.test.ts index c64a98ecd34..0d4f388d0e7 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookKernelService.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookKernelService.test.ts @@ -6,7 +6,7 @@ import * as assert from 'assert'; import { URI } from 'vs/base/common/uri'; import { ExtensionIdentifier } from 'vs/platform/extensions/common/extensions'; -import { setupInstantiationService, withTestNotebook as _withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, withTestNotebook as _withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; import { Emitter, Event } from 'vs/base/common/event'; import { INotebookKernel, INotebookKernelService } from 'vs/workbench/contrib/notebook/common/notebookKernelService'; import { NotebookKernelService } from 'vs/workbench/contrib/notebook/browser/notebookKernelServiceImpl'; diff --git a/src/vs/workbench/contrib/notebook/test/notebookRendererMessagingService.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookRendererMessagingService.test.ts similarity index 100% rename from src/vs/workbench/contrib/notebook/test/notebookRendererMessagingService.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookRendererMessagingService.test.ts diff --git a/src/vs/workbench/contrib/notebook/test/notebookSelection.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookSelection.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookSelection.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookSelection.test.ts index 83eaf9d1930..9381405d7c8 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookSelection.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookSelection.test.ts @@ -11,7 +11,7 @@ import { FoldingModel, updateFoldingStateAtIndex } from 'vs/workbench/contrib/no import { runDeleteAction } from 'vs/workbench/contrib/notebook/browser/controller/cellOperations'; import { NotebookCellSelectionCollection } from 'vs/workbench/contrib/notebook/browser/viewModel/cellSelectionCollection'; import { CellEditType, CellKind, SelectionStateType } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { createNotebookCellList, setupInstantiationService, TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { createNotebookCellList, setupInstantiationService, TestCell, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookSelection', () => { test('focus is never empty', function () { diff --git a/src/vs/workbench/contrib/notebook/test/notebookServiceImpl.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookServiceImpl.test.ts similarity index 100% rename from src/vs/workbench/contrib/notebook/test/notebookServiceImpl.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookServiceImpl.test.ts diff --git a/src/vs/workbench/contrib/notebook/test/notebookTextModel.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookTextModel.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookTextModel.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookTextModel.test.ts index 8123bba2a1d..e2253a7544b 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookTextModel.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookTextModel.test.ts @@ -11,7 +11,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { IUndoRedoService } from 'vs/platform/undoRedo/common/undoRedo'; import { CellEditType, CellKind, ICellEditOperation, NotebookTextModelChangedEvent, NotebookTextModelWillAddRemoveEvent, SelectionStateType } from 'vs/workbench/contrib/notebook/common/notebookCommon'; -import { setupInstantiationService, TestCell, valueBytesFromString, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { setupInstantiationService, TestCell, valueBytesFromString, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookTextModel', () => { let disposables: DisposableStore; diff --git a/src/vs/workbench/contrib/notebook/test/notebookViewModel.test.ts b/src/vs/workbench/contrib/notebook/test/browser/notebookViewModel.test.ts similarity index 99% rename from src/vs/workbench/contrib/notebook/test/notebookViewModel.test.ts rename to src/vs/workbench/contrib/notebook/test/browser/notebookViewModel.test.ts index e716fb3dc00..7b7346c2dae 100644 --- a/src/vs/workbench/contrib/notebook/test/notebookViewModel.test.ts +++ b/src/vs/workbench/contrib/notebook/test/browser/notebookViewModel.test.ts @@ -25,7 +25,7 @@ import { NotebookTextModel } from 'vs/workbench/contrib/notebook/common/model/no import { CellKind, diff } from 'vs/workbench/contrib/notebook/common/notebookCommon'; import { NotebookOptions } from 'vs/workbench/contrib/notebook/common/notebookOptions'; import { ICellRange } from 'vs/workbench/contrib/notebook/common/notebookRange'; -import { NotebookEditorTestModel, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/testNotebookEditor'; +import { NotebookEditorTestModel, setupInstantiationService, withTestNotebook } from 'vs/workbench/contrib/notebook/test/browser/testNotebookEditor'; suite('NotebookViewModel', () => { let disposables: DisposableStore; diff --git a/src/vs/workbench/contrib/notebook/test/testNotebookEditor.ts b/src/vs/workbench/contrib/notebook/test/browser/testNotebookEditor.ts similarity index 100% rename from src/vs/workbench/contrib/notebook/test/testNotebookEditor.ts rename to src/vs/workbench/contrib/notebook/test/browser/testNotebookEditor.ts diff --git a/test/unit/node/all.js b/test/unit/node/all.js index a1421c5c72c..dc9b21fac2c 100644 --- a/test/unit/node/all.js +++ b/test/unit/node/all.js @@ -10,9 +10,8 @@ const assert = require('assert'); const path = require('path'); const glob = require('glob'); const jsdom = require('jsdom-no-contextify'); -const TEST_GLOB = '**/test/**/*.test.js'; +const minimatch = require('minimatch'); const coverage = require('../coverage'); - const optimist = require('optimist') .usage('Run the Code tests. All mocha options apply.') .describe('build', 'Run from out-build').boolean('build') @@ -22,6 +21,9 @@ const optimist = require('optimist') .alias('h', 'help').boolean('h') .describe('h', 'Show help'); +const TEST_GLOB = '**/test/**/*.test.js'; +const excludeGlob = '**/{browser,electron-sandbox,electron-browser,electron-main,editor/contrib}/**/*.test.js'; + const argv = optimist.argv; if (argv.help) { @@ -112,10 +114,13 @@ function main() { } else { loadFunc = (cb) => { glob(TEST_GLOB, { cwd: src }, function (err, files) { - const modulesToLoad = files.map(function (file) { - return file.replace(/\.js$/, ''); - }); - define(modulesToLoad, function () { cb(null); }, cb); + const modules = []; + for (let file of files) { + if (!minimatch(file, excludeGlob)) { + modules.push(file.replace(/\.js$/, '')); + } + } + define(modules, function () { cb(null); }, cb); }); }; }