@codingame/monaco-vscode-testing-service-override 3.2.3 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +8 -8
- package/testing.js +5 -4
- package/external/rollup-plugin-styles/dist/runtime/inject-css.js +0 -3
- package/external/tslib/tslib.es6.js +0 -11
- package/vscode/src/vs/workbench/contrib/testing/browser/codeCoverageDecorations.js +0 -567
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/display.js +0 -3
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/index.js +0 -83
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/listProjection.js +0 -186
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/testItemContextOverlay.js +0 -18
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/testingObjectTree.js +0 -46
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/testingViewState.js +0 -17
- package/vscode/src/vs/workbench/contrib/testing/browser/explorerProjections/treeProjection.js +0 -225
- package/vscode/src/vs/workbench/contrib/testing/browser/icons.js +0 -174
- package/vscode/src/vs/workbench/contrib/testing/browser/media/testing.css.js +0 -6
- package/vscode/src/vs/workbench/contrib/testing/browser/testCoverageBars.js +0 -227
- package/vscode/src/vs/workbench/contrib/testing/browser/testCoverageView.js +0 -545
- package/vscode/src/vs/workbench/contrib/testing/browser/testExplorerActions.js +0 -1662
- package/vscode/src/vs/workbench/contrib/testing/browser/testing.contribution.js +0 -219
- package/vscode/src/vs/workbench/contrib/testing/browser/testingDecorations.js +0 -970
- package/vscode/src/vs/workbench/contrib/testing/browser/testingExplorerFilter.js +0 -236
- package/vscode/src/vs/workbench/contrib/testing/browser/testingExplorerView.js +0 -1227
- package/vscode/src/vs/workbench/contrib/testing/browser/testingOutputPeek.css.js +0 -6
- package/vscode/src/vs/workbench/contrib/testing/browser/testingOutputPeek.js +0 -2091
- package/vscode/src/vs/workbench/contrib/testing/browser/testingProgressUiService.js +0 -142
- package/vscode/src/vs/workbench/contrib/testing/browser/testingViewPaneContainer.js +0 -47
- package/vscode/src/vs/workbench/contrib/testing/browser/theme.js +0 -259
- package/vscode/src/vs/workbench/contrib/testing/common/configuration.js +0 -273
- package/vscode/src/vs/workbench/contrib/testing/common/constants.js +0 -59
- package/vscode/src/vs/workbench/contrib/testing/common/mainThreadTestCollection.js +0 -129
- package/vscode/src/vs/workbench/contrib/testing/common/testExclusions.js +0 -48
- package/vscode/src/vs/workbench/contrib/testing/common/testServiceImpl.js +0 -296
- package/vscode/src/vs/workbench/contrib/testing/common/testingContentProvider.js +0 -125
- package/vscode/src/vs/workbench/contrib/testing/common/testingUri.js +0 -67
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { Disposable, DisposableStore } from 'vscode/vscode/vs/base/common/lifecycle';
|
|
3
|
-
import { localizeWithPath } from 'vscode/vscode/vs/nls';
|
|
4
|
-
import { IConfigurationService } from 'vscode/vscode/vs/platform/configuration/common/configuration';
|
|
5
|
-
import { IViewsService } from 'vscode/vscode/vs/workbench/services/views/common/viewsService';
|
|
6
|
-
import { getTestingConfiguration } from '../common/configuration.js';
|
|
7
|
-
import { isFailedState } from 'vscode/vscode/vs/workbench/contrib/testing/common/testingStates';
|
|
8
|
-
import { ITestResultService } from 'vscode/vscode/vs/workbench/contrib/testing/common/testResultService';
|
|
9
|
-
|
|
10
|
-
let TestingProgressTrigger = class TestingProgressTrigger extends Disposable {
|
|
11
|
-
constructor(resultService, configurationService, viewsService) {
|
|
12
|
-
super();
|
|
13
|
-
this.configurationService = configurationService;
|
|
14
|
-
this.viewsService = viewsService;
|
|
15
|
-
this._register(resultService.onResultsChanged((e) => {
|
|
16
|
-
if ('started' in e) {
|
|
17
|
-
this.attachAutoOpenForNewResults(e.started);
|
|
18
|
-
}
|
|
19
|
-
}));
|
|
20
|
-
}
|
|
21
|
-
attachAutoOpenForNewResults(result) {
|
|
22
|
-
if (result.request.isUiTriggered === false) {
|
|
23
|
-
return;
|
|
24
|
-
}
|
|
25
|
-
const cfg = getTestingConfiguration(this.configurationService, "testing.openTesting" );
|
|
26
|
-
if (cfg === "neverOpen" ) {
|
|
27
|
-
return;
|
|
28
|
-
}
|
|
29
|
-
if (cfg === "openExplorerOnTestStart" ) {
|
|
30
|
-
return this.openExplorerView();
|
|
31
|
-
}
|
|
32
|
-
if (cfg === "openOnTestStart" ) {
|
|
33
|
-
return this.openResultsView();
|
|
34
|
-
}
|
|
35
|
-
const disposable = ( new DisposableStore());
|
|
36
|
-
disposable.add(result.onComplete(() => disposable.dispose()));
|
|
37
|
-
disposable.add(result.onChange(e => {
|
|
38
|
-
if (e.reason === 1 && isFailedState(e.item.ownComputedState)) {
|
|
39
|
-
this.openResultsView();
|
|
40
|
-
disposable.dispose();
|
|
41
|
-
}
|
|
42
|
-
}));
|
|
43
|
-
}
|
|
44
|
-
openExplorerView() {
|
|
45
|
-
this.viewsService.openView("workbench.view.testing" , false);
|
|
46
|
-
}
|
|
47
|
-
openResultsView() {
|
|
48
|
-
this.viewsService.openView("workbench.panel.testResults.view" , false);
|
|
49
|
-
}
|
|
50
|
-
};
|
|
51
|
-
TestingProgressTrigger = ( __decorate([
|
|
52
|
-
( __param(0, ITestResultService)),
|
|
53
|
-
( __param(1, IConfigurationService)),
|
|
54
|
-
( __param(2, IViewsService))
|
|
55
|
-
], TestingProgressTrigger));
|
|
56
|
-
const collectTestStateCounts = (isRunning, results) => {
|
|
57
|
-
let passed = 0;
|
|
58
|
-
let failed = 0;
|
|
59
|
-
let skipped = 0;
|
|
60
|
-
let running = 0;
|
|
61
|
-
let queued = 0;
|
|
62
|
-
for (const result of results) {
|
|
63
|
-
const count = result.counts;
|
|
64
|
-
failed += count[6 ] + count[4 ];
|
|
65
|
-
passed += count[3 ];
|
|
66
|
-
skipped += count[5 ];
|
|
67
|
-
running += count[2 ];
|
|
68
|
-
queued += count[1 ];
|
|
69
|
-
}
|
|
70
|
-
return {
|
|
71
|
-
isRunning,
|
|
72
|
-
passed,
|
|
73
|
-
failed,
|
|
74
|
-
runSoFar: passed + failed,
|
|
75
|
-
totalWillBeRun: passed + failed + queued + running,
|
|
76
|
-
skipped,
|
|
77
|
-
};
|
|
78
|
-
};
|
|
79
|
-
const getTestProgressText = ({ isRunning, passed, runSoFar, totalWillBeRun, skipped, failed }) => {
|
|
80
|
-
let percent = passed / runSoFar * 100;
|
|
81
|
-
if (failed > 0) {
|
|
82
|
-
percent = Math.min(percent, 99.9);
|
|
83
|
-
}
|
|
84
|
-
else if (runSoFar === 0) {
|
|
85
|
-
percent = 0;
|
|
86
|
-
}
|
|
87
|
-
if (isRunning) {
|
|
88
|
-
if (runSoFar === 0) {
|
|
89
|
-
return ( localizeWithPath(
|
|
90
|
-
'vs/workbench/contrib/testing/browser/testingProgressUiService',
|
|
91
|
-
'testProgress.runningInitial',
|
|
92
|
-
'Running tests...'
|
|
93
|
-
));
|
|
94
|
-
}
|
|
95
|
-
else if (skipped === 0) {
|
|
96
|
-
return ( localizeWithPath(
|
|
97
|
-
'vs/workbench/contrib/testing/browser/testingProgressUiService',
|
|
98
|
-
'testProgress.running',
|
|
99
|
-
'Running tests, {0}/{1} passed ({2}%)',
|
|
100
|
-
passed,
|
|
101
|
-
totalWillBeRun,
|
|
102
|
-
percent.toPrecision(3)
|
|
103
|
-
));
|
|
104
|
-
}
|
|
105
|
-
else {
|
|
106
|
-
return ( localizeWithPath(
|
|
107
|
-
'vs/workbench/contrib/testing/browser/testingProgressUiService',
|
|
108
|
-
'testProgressWithSkip.running',
|
|
109
|
-
'Running tests, {0}/{1} tests passed ({2}%, {3} skipped)',
|
|
110
|
-
passed,
|
|
111
|
-
totalWillBeRun,
|
|
112
|
-
percent.toPrecision(3),
|
|
113
|
-
skipped
|
|
114
|
-
));
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
else {
|
|
118
|
-
if (skipped === 0) {
|
|
119
|
-
return ( localizeWithPath(
|
|
120
|
-
'vs/workbench/contrib/testing/browser/testingProgressUiService',
|
|
121
|
-
'testProgress.completed',
|
|
122
|
-
'{0}/{1} tests passed ({2}%)',
|
|
123
|
-
passed,
|
|
124
|
-
runSoFar,
|
|
125
|
-
percent.toPrecision(3)
|
|
126
|
-
));
|
|
127
|
-
}
|
|
128
|
-
else {
|
|
129
|
-
return ( localizeWithPath(
|
|
130
|
-
'vs/workbench/contrib/testing/browser/testingProgressUiService',
|
|
131
|
-
'testProgressWithSkip.completed',
|
|
132
|
-
'{0}/{1} tests passed ({2}%, {3} skipped)',
|
|
133
|
-
passed,
|
|
134
|
-
runSoFar,
|
|
135
|
-
percent.toPrecision(3),
|
|
136
|
-
skipped
|
|
137
|
-
));
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
};
|
|
141
|
-
|
|
142
|
-
export { TestingProgressTrigger, collectTestStateCounts, getTestProgressText };
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { __decorate, __param } from '../../../../../../../external/tslib/tslib.es6.js';
|
|
2
|
-
import { localizeWithPath } from 'vscode/vscode/vs/nls';
|
|
3
|
-
import { IConfigurationService } from 'vscode/vscode/vs/platform/configuration/common/configuration';
|
|
4
|
-
import { IContextMenuService } from 'vscode/vscode/vs/platform/contextview/browser/contextView';
|
|
5
|
-
import { IInstantiationService } from 'vscode/vscode/vs/platform/instantiation/common/instantiation';
|
|
6
|
-
import { IStorageService } from 'vscode/vscode/vs/platform/storage/common/storage';
|
|
7
|
-
import { ITelemetryService } from 'vscode/vscode/vs/platform/telemetry/common/telemetry';
|
|
8
|
-
import { IThemeService } from 'vscode/vscode/vs/platform/theme/common/themeService';
|
|
9
|
-
import { IWorkspaceContextService } from 'vscode/vscode/vs/platform/workspace/common/workspace';
|
|
10
|
-
import { ViewPaneContainer } from 'vscode/vscode/vs/workbench/browser/parts/views/viewPaneContainer';
|
|
11
|
-
import { IViewDescriptorService } from 'vscode/vscode/vs/workbench/common/views';
|
|
12
|
-
import { IExtensionService } from 'vscode/vscode/vs/workbench/services/extensions/common/extensions';
|
|
13
|
-
import { IWorkbenchLayoutService } from 'vscode/vscode/vs/workbench/services/layout/browser/layoutService';
|
|
14
|
-
|
|
15
|
-
let TestingViewPaneContainer = class TestingViewPaneContainer extends ViewPaneContainer {
|
|
16
|
-
constructor(layoutService, telemetryService, instantiationService, contextMenuService, themeService, storageService, configurationService, extensionService, contextService, viewDescriptorService) {
|
|
17
|
-
super("workbench.view.extension.test" , { mergeViewWithContainerWhenSingleView: true }, instantiationService, configurationService, layoutService, contextMenuService, telemetryService, extensionService, themeService, storageService, contextService, viewDescriptorService);
|
|
18
|
-
}
|
|
19
|
-
create(parent) {
|
|
20
|
-
super.create(parent);
|
|
21
|
-
parent.classList.add('testing-view-pane');
|
|
22
|
-
}
|
|
23
|
-
getOptimalWidth() {
|
|
24
|
-
return 400;
|
|
25
|
-
}
|
|
26
|
-
getTitle() {
|
|
27
|
-
return ( localizeWithPath(
|
|
28
|
-
'vs/workbench/contrib/testing/browser/testingViewPaneContainer',
|
|
29
|
-
'testing',
|
|
30
|
-
"Testing"
|
|
31
|
-
));
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
TestingViewPaneContainer = ( __decorate([
|
|
35
|
-
( __param(0, IWorkbenchLayoutService)),
|
|
36
|
-
( __param(1, ITelemetryService)),
|
|
37
|
-
( __param(2, IInstantiationService)),
|
|
38
|
-
( __param(3, IContextMenuService)),
|
|
39
|
-
( __param(4, IThemeService)),
|
|
40
|
-
( __param(5, IStorageService)),
|
|
41
|
-
( __param(6, IConfigurationService)),
|
|
42
|
-
( __param(7, IExtensionService)),
|
|
43
|
-
( __param(8, IWorkspaceContextService)),
|
|
44
|
-
( __param(9, IViewDescriptorService))
|
|
45
|
-
], TestingViewPaneContainer));
|
|
46
|
-
|
|
47
|
-
export { TestingViewPaneContainer };
|
|
@@ -1,259 +0,0 @@
|
|
|
1
|
-
import { Color, RGBA } from 'vscode/vscode/vs/base/common/color';
|
|
2
|
-
import { localizeWithPath } from 'vscode/vscode/vs/nls';
|
|
3
|
-
import { registerColor, editorErrorForeground, contrastBorder, editorInfoForeground, transparent, diffInserted, chartsGreen, opaque, diffRemoved, editorBackground, chartsRed, badgeBackground, badgeForeground, editorForeground } from 'vscode/vscode/vs/platform/theme/common/colorRegistry';
|
|
4
|
-
import { registerThemingParticipant } from 'vscode/vscode/vs/platform/theme/common/themeService';
|
|
5
|
-
|
|
6
|
-
const testingColorIconFailed = registerColor('testing.iconFailed', {
|
|
7
|
-
dark: '#f14c4c',
|
|
8
|
-
light: '#f14c4c',
|
|
9
|
-
hcDark: '#f14c4c',
|
|
10
|
-
hcLight: '#B5200D'
|
|
11
|
-
}, ( localizeWithPath(
|
|
12
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
13
|
-
'testing.iconFailed',
|
|
14
|
-
"Color for the 'failed' icon in the test explorer."
|
|
15
|
-
)));
|
|
16
|
-
const testingColorIconErrored = registerColor('testing.iconErrored', {
|
|
17
|
-
dark: '#f14c4c',
|
|
18
|
-
light: '#f14c4c',
|
|
19
|
-
hcDark: '#f14c4c',
|
|
20
|
-
hcLight: '#B5200D'
|
|
21
|
-
}, ( localizeWithPath(
|
|
22
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
23
|
-
'testing.iconErrored',
|
|
24
|
-
"Color for the 'Errored' icon in the test explorer."
|
|
25
|
-
)));
|
|
26
|
-
const testingColorIconPassed = registerColor('testing.iconPassed', {
|
|
27
|
-
dark: '#73c991',
|
|
28
|
-
light: '#73c991',
|
|
29
|
-
hcDark: '#73c991',
|
|
30
|
-
hcLight: '#007100'
|
|
31
|
-
}, ( localizeWithPath(
|
|
32
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
33
|
-
'testing.iconPassed',
|
|
34
|
-
"Color for the 'passed' icon in the test explorer."
|
|
35
|
-
)));
|
|
36
|
-
const testingColorRunAction = registerColor('testing.runAction', {
|
|
37
|
-
dark: testingColorIconPassed,
|
|
38
|
-
light: testingColorIconPassed,
|
|
39
|
-
hcDark: testingColorIconPassed,
|
|
40
|
-
hcLight: testingColorIconPassed
|
|
41
|
-
}, ( localizeWithPath(
|
|
42
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
43
|
-
'testing.runAction',
|
|
44
|
-
"Color for 'run' icons in the editor."
|
|
45
|
-
)));
|
|
46
|
-
const testingColorIconQueued = registerColor('testing.iconQueued', {
|
|
47
|
-
dark: '#cca700',
|
|
48
|
-
light: '#cca700',
|
|
49
|
-
hcDark: '#cca700',
|
|
50
|
-
hcLight: '#cca700'
|
|
51
|
-
}, ( localizeWithPath(
|
|
52
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
53
|
-
'testing.iconQueued',
|
|
54
|
-
"Color for the 'Queued' icon in the test explorer."
|
|
55
|
-
)));
|
|
56
|
-
const testingColorIconUnset = registerColor('testing.iconUnset', {
|
|
57
|
-
dark: '#848484',
|
|
58
|
-
light: '#848484',
|
|
59
|
-
hcDark: '#848484',
|
|
60
|
-
hcLight: '#848484'
|
|
61
|
-
}, ( localizeWithPath(
|
|
62
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
63
|
-
'testing.iconUnset',
|
|
64
|
-
"Color for the 'Unset' icon in the test explorer."
|
|
65
|
-
)));
|
|
66
|
-
const testingColorIconSkipped = registerColor('testing.iconSkipped', {
|
|
67
|
-
dark: '#848484',
|
|
68
|
-
light: '#848484',
|
|
69
|
-
hcDark: '#848484',
|
|
70
|
-
hcLight: '#848484'
|
|
71
|
-
}, ( localizeWithPath(
|
|
72
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
73
|
-
'testing.iconSkipped',
|
|
74
|
-
"Color for the 'Skipped' icon in the test explorer."
|
|
75
|
-
)));
|
|
76
|
-
const testingPeekBorder = registerColor('testing.peekBorder', {
|
|
77
|
-
dark: editorErrorForeground,
|
|
78
|
-
light: editorErrorForeground,
|
|
79
|
-
hcDark: contrastBorder,
|
|
80
|
-
hcLight: contrastBorder
|
|
81
|
-
}, ( localizeWithPath(
|
|
82
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
83
|
-
'testing.peekBorder',
|
|
84
|
-
'Color of the peek view borders and arrow.'
|
|
85
|
-
)));
|
|
86
|
-
const testingMessagePeekBorder = registerColor('testing.messagePeekBorder', {
|
|
87
|
-
dark: editorInfoForeground,
|
|
88
|
-
light: editorInfoForeground,
|
|
89
|
-
hcDark: contrastBorder,
|
|
90
|
-
hcLight: contrastBorder
|
|
91
|
-
}, ( localizeWithPath(
|
|
92
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
93
|
-
'testing.messagePeekBorder',
|
|
94
|
-
'Color of the peek view borders and arrow when peeking a logged message.'
|
|
95
|
-
)));
|
|
96
|
-
const testingPeekHeaderBackground = registerColor('testing.peekHeaderBackground', {
|
|
97
|
-
dark: ( transparent(editorErrorForeground, 0.1)),
|
|
98
|
-
light: ( transparent(editorErrorForeground, 0.1)),
|
|
99
|
-
hcDark: null,
|
|
100
|
-
hcLight: null
|
|
101
|
-
}, ( localizeWithPath(
|
|
102
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
103
|
-
'testing.peekBorder',
|
|
104
|
-
'Color of the peek view borders and arrow.'
|
|
105
|
-
)));
|
|
106
|
-
const testingPeekMessageHeaderBackground = registerColor('testing.messagePeekHeaderBackground', {
|
|
107
|
-
dark: ( transparent(editorInfoForeground, 0.1)),
|
|
108
|
-
light: ( transparent(editorInfoForeground, 0.1)),
|
|
109
|
-
hcDark: null,
|
|
110
|
-
hcLight: null
|
|
111
|
-
}, ( localizeWithPath(
|
|
112
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
113
|
-
'testing.messagePeekHeaderBackground',
|
|
114
|
-
'Color of the peek view borders and arrow when peeking a logged message.'
|
|
115
|
-
)));
|
|
116
|
-
const testingCoveredBackground = registerColor('testing.coveredBackground', {
|
|
117
|
-
dark: diffInserted,
|
|
118
|
-
light: diffInserted,
|
|
119
|
-
hcDark: null,
|
|
120
|
-
hcLight: null
|
|
121
|
-
}, ( localizeWithPath(
|
|
122
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
123
|
-
'testing.coveredBackground',
|
|
124
|
-
'Background color of text that was covered.'
|
|
125
|
-
)));
|
|
126
|
-
const testingCoveredBorder = registerColor('testing.coveredBorder', {
|
|
127
|
-
dark: ( transparent(testingCoveredBackground, 0.75)),
|
|
128
|
-
light: ( transparent(testingCoveredBackground, 0.75)),
|
|
129
|
-
hcDark: contrastBorder,
|
|
130
|
-
hcLight: contrastBorder
|
|
131
|
-
}, ( localizeWithPath(
|
|
132
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
133
|
-
'testing.coveredBorder',
|
|
134
|
-
'Border color of text that was covered.'
|
|
135
|
-
)));
|
|
136
|
-
registerColor('testing.coveredGutterBackground', {
|
|
137
|
-
dark: ( transparent(diffInserted, 0.6)),
|
|
138
|
-
light: ( transparent(diffInserted, 0.6)),
|
|
139
|
-
hcDark: chartsGreen,
|
|
140
|
-
hcLight: chartsGreen
|
|
141
|
-
}, ( localizeWithPath(
|
|
142
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
143
|
-
'testing.coveredGutterBackground',
|
|
144
|
-
'Gutter color of regions where code was covered.'
|
|
145
|
-
)));
|
|
146
|
-
registerColor('testing.uncoveredBranchBackground', {
|
|
147
|
-
dark: opaque(( transparent(diffRemoved, 2)), editorBackground),
|
|
148
|
-
light: opaque(( transparent(diffRemoved, 2)), editorBackground),
|
|
149
|
-
hcDark: null,
|
|
150
|
-
hcLight: null
|
|
151
|
-
}, ( localizeWithPath(
|
|
152
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
153
|
-
'testing.uncoveredBranchBackground',
|
|
154
|
-
'Background of the widget shown for an uncovered branch.'
|
|
155
|
-
)));
|
|
156
|
-
const testingUncoveredBackground = registerColor('testing.uncoveredBackground', {
|
|
157
|
-
dark: diffRemoved,
|
|
158
|
-
light: diffRemoved,
|
|
159
|
-
hcDark: null,
|
|
160
|
-
hcLight: null
|
|
161
|
-
}, ( localizeWithPath(
|
|
162
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
163
|
-
'testing.uncoveredBackground',
|
|
164
|
-
'Background color of text that was not covered.'
|
|
165
|
-
)));
|
|
166
|
-
const testingUncoveredBorder = registerColor('testing.uncoveredBorder', {
|
|
167
|
-
dark: ( transparent(testingUncoveredBackground, 0.75)),
|
|
168
|
-
light: ( transparent(testingUncoveredBackground, 0.75)),
|
|
169
|
-
hcDark: contrastBorder,
|
|
170
|
-
hcLight: contrastBorder
|
|
171
|
-
}, ( localizeWithPath(
|
|
172
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
173
|
-
'testing.uncoveredBorder',
|
|
174
|
-
'Border color of text that was not covered.'
|
|
175
|
-
)));
|
|
176
|
-
registerColor('testing.uncoveredGutterBackground', {
|
|
177
|
-
dark: ( transparent(diffRemoved, 1.5)),
|
|
178
|
-
light: ( transparent(diffRemoved, 1.5)),
|
|
179
|
-
hcDark: chartsRed,
|
|
180
|
-
hcLight: chartsRed
|
|
181
|
-
}, ( localizeWithPath(
|
|
182
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
183
|
-
'testing.uncoveredGutterBackground',
|
|
184
|
-
'Gutter color of regions where code not covered.'
|
|
185
|
-
)));
|
|
186
|
-
registerColor('testing.coverCountBadgeBackground', {
|
|
187
|
-
dark: badgeBackground,
|
|
188
|
-
light: badgeBackground,
|
|
189
|
-
hcDark: badgeBackground,
|
|
190
|
-
hcLight: badgeBackground
|
|
191
|
-
}, ( localizeWithPath(
|
|
192
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
193
|
-
'testing.coverCountBadgeBackground',
|
|
194
|
-
'Background for the badge indicating execution count'
|
|
195
|
-
)));
|
|
196
|
-
registerColor('testing.coverCountBadgeForeground', {
|
|
197
|
-
dark: badgeForeground,
|
|
198
|
-
light: badgeForeground,
|
|
199
|
-
hcDark: badgeForeground,
|
|
200
|
-
hcLight: badgeForeground
|
|
201
|
-
}, ( localizeWithPath(
|
|
202
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
203
|
-
'testing.coverCountBadgeForeground',
|
|
204
|
-
'Foreground for the badge indicating execution count'
|
|
205
|
-
)));
|
|
206
|
-
({
|
|
207
|
-
[0 ]: {
|
|
208
|
-
decorationForeground: registerColor('testing.message.error.decorationForeground', { dark: editorErrorForeground, light: editorErrorForeground, hcDark: editorForeground, hcLight: editorForeground }, ( localizeWithPath(
|
|
209
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
210
|
-
'testing.message.error.decorationForeground',
|
|
211
|
-
'Text color of test error messages shown inline in the editor.'
|
|
212
|
-
))),
|
|
213
|
-
marginBackground: registerColor('testing.message.error.lineBackground', { dark: ( new Color(( new RGBA(255, 0, 0, 0.2)))), light: ( new Color(( new RGBA(255, 0, 0, 0.2)))), hcDark: null, hcLight: null }, ( localizeWithPath(
|
|
214
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
215
|
-
'testing.message.error.marginBackground',
|
|
216
|
-
'Margin color beside error messages shown inline in the editor.'
|
|
217
|
-
))),
|
|
218
|
-
},
|
|
219
|
-
[1 ]: {
|
|
220
|
-
decorationForeground: registerColor('testing.message.info.decorationForeground', { dark: ( transparent(editorForeground, 0.5)), light: ( transparent(editorForeground, 0.5)), hcDark: ( transparent(editorForeground, 0.5)), hcLight: ( transparent(editorForeground, 0.5)) }, ( localizeWithPath(
|
|
221
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
222
|
-
'testing.message.info.decorationForeground',
|
|
223
|
-
'Text color of test info messages shown inline in the editor.'
|
|
224
|
-
))),
|
|
225
|
-
marginBackground: registerColor('testing.message.info.lineBackground', { dark: null, light: null, hcDark: null, hcLight: null }, ( localizeWithPath(
|
|
226
|
-
'vs/workbench/contrib/testing/browser/theme',
|
|
227
|
-
'testing.message.info.marginBackground',
|
|
228
|
-
'Margin color beside info messages shown inline in the editor.'
|
|
229
|
-
))),
|
|
230
|
-
},
|
|
231
|
-
});
|
|
232
|
-
const testStatesToIconColors = {
|
|
233
|
-
[6 ]: testingColorIconErrored,
|
|
234
|
-
[4 ]: testingColorIconFailed,
|
|
235
|
-
[3 ]: testingColorIconPassed,
|
|
236
|
-
[1 ]: testingColorIconQueued,
|
|
237
|
-
[0 ]: testingColorIconUnset,
|
|
238
|
-
[5 ]: testingColorIconSkipped,
|
|
239
|
-
};
|
|
240
|
-
registerThemingParticipant((theme, collector) => {
|
|
241
|
-
const editorBg = theme.getColor(editorBackground);
|
|
242
|
-
const missBadgeBackground = editorBg && theme.getColor(testingUncoveredBackground)?.transparent(2).makeOpaque(editorBg);
|
|
243
|
-
collector.addRule(`
|
|
244
|
-
.coverage-deco-inline.coverage-deco-hit.coverage-deco-hovered {
|
|
245
|
-
background: ${theme.getColor(testingCoveredBackground)?.transparent(1.3)};
|
|
246
|
-
outline-color: ${theme.getColor(testingCoveredBorder)?.transparent(2)};
|
|
247
|
-
}
|
|
248
|
-
.coverage-deco-inline.coverage-deco-miss.coverage-deco-hovered {
|
|
249
|
-
background: ${theme.getColor(testingUncoveredBackground)?.transparent(1.3)};
|
|
250
|
-
outline-color: ${theme.getColor(testingUncoveredBorder)?.transparent(2)};
|
|
251
|
-
}
|
|
252
|
-
.coverage-deco-branch-miss-indicator::before {
|
|
253
|
-
border-color: ${missBadgeBackground?.transparent(1.3)};
|
|
254
|
-
background-color: ${missBadgeBackground};
|
|
255
|
-
}
|
|
256
|
-
`);
|
|
257
|
-
});
|
|
258
|
-
|
|
259
|
-
export { testStatesToIconColors, testingColorIconErrored, testingColorIconFailed, testingColorIconPassed, testingColorIconQueued, testingColorIconSkipped, testingColorIconUnset, testingColorRunAction, testingCoveredBackground, testingCoveredBorder, testingMessagePeekBorder, testingPeekBorder, testingPeekHeaderBackground, testingPeekMessageHeaderBackground, testingUncoveredBackground, testingUncoveredBorder };
|