@codingame/monaco-vscode-testing-service-override 29.1.1 → 30.0.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 +4 -4
- package/vscode/src/vs/workbench/contrib/debug/browser/callStackWidget.js +5 -5
- package/vscode/src/vs/workbench/contrib/testing/browser/codeCoverageDecorations.js +21 -21
- package/vscode/src/vs/workbench/contrib/testing/browser/codeCoverageDisplayUtils.js +5 -5
- package/vscode/src/vs/workbench/contrib/testing/browser/icons.js +29 -29
- package/vscode/src/vs/workbench/contrib/testing/browser/testCoverageBars.js +3 -3
- package/vscode/src/vs/workbench/contrib/testing/browser/testCoverageView.d.ts +3 -1
- package/vscode/src/vs/workbench/contrib/testing/browser/testCoverageView.js +34 -17
- package/vscode/src/vs/workbench/contrib/testing/browser/testExplorerActions.js +72 -72
- package/vscode/src/vs/workbench/contrib/testing/browser/testResultsView/testResultsOutput.js +5 -5
- package/vscode/src/vs/workbench/contrib/testing/browser/testResultsView/testResultsTree.js +22 -22
- package/vscode/src/vs/workbench/contrib/testing/browser/testResultsView/testResultsViewContent.js +3 -3
- package/vscode/src/vs/workbench/contrib/testing/browser/testing.contribution.js +8 -8
- package/vscode/src/vs/workbench/contrib/testing/browser/testingConfigurationUi.js +2 -2
- package/vscode/src/vs/workbench/contrib/testing/browser/testingDecorations.js +19 -19
- package/vscode/src/vs/workbench/contrib/testing/browser/testingExplorerFilter.js +11 -11
- package/vscode/src/vs/workbench/contrib/testing/browser/testingExplorerView.js +15 -15
- package/vscode/src/vs/workbench/contrib/testing/browser/testingOutputPeek.js +11 -11
- package/vscode/src/vs/workbench/contrib/testing/browser/testingViewPaneContainer.js +1 -1
- package/vscode/src/vs/workbench/contrib/testing/browser/theme.js +33 -43
- package/vscode/src/vs/workbench/contrib/testing/common/configuration.js +24 -24
- package/vscode/src/vs/workbench/contrib/testing/common/testServiceImpl.js +4 -4
- package/vscode/src/vs/workbench/contrib/testing/common/testingChatAgentTool.js +11 -11
- package/vscode/src/vs/workbench/contrib/testing/common/testingContentProvider.js +1 -1
- package/vscode/src/vs/workbench/contrib/testing/common/testingContextKeys.js +31 -31
- package/vscode/src/vs/workbench/contrib/testing/common/testingProgressMessages.js +5 -5
|
@@ -5,7 +5,7 @@ import { contrastBorder } from '@codingame/monaco-vscode-api/vscode/vs/platform/
|
|
|
5
5
|
import { chartsGreen, chartsRed } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/chartsColors';
|
|
6
6
|
import { editorErrorForeground, editorInfoForeground, diffInserted, diffRemoved, editorBackground, editorForeground } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/editorColors';
|
|
7
7
|
import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/inputColors';
|
|
8
|
-
import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/listColors';
|
|
8
|
+
import { listErrorForeground, listWarningForeground } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/listColors';
|
|
9
9
|
import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/menuColors';
|
|
10
10
|
import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/minimapColors';
|
|
11
11
|
import { badgeBackground, badgeForeground, activityErrorBadgeBackground, activityErrorBadgeForeground } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/miscColors';
|
|
@@ -14,41 +14,31 @@ import '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/colors/sear
|
|
|
14
14
|
import { registerThemingParticipant } from '@codingame/monaco-vscode-api/vscode/vs/platform/theme/common/themeService';
|
|
15
15
|
import { TestResultState } from '@codingame/monaco-vscode-api/vscode/vs/workbench/contrib/testing/common/testTypes';
|
|
16
16
|
|
|
17
|
-
const testingColorIconFailed = registerColor("testing.iconFailed",
|
|
18
|
-
|
|
19
|
-
light: "#f14c4c",
|
|
20
|
-
hcDark: "#f14c4c",
|
|
21
|
-
hcLight: "#B5200D"
|
|
22
|
-
}, ( localize(14498, "Color for the 'failed' icon in the test explorer.")));
|
|
23
|
-
const testingColorIconErrored = registerColor("testing.iconErrored", {
|
|
24
|
-
dark: "#f14c4c",
|
|
25
|
-
light: "#f14c4c",
|
|
26
|
-
hcDark: "#f14c4c",
|
|
27
|
-
hcLight: "#B5200D"
|
|
28
|
-
}, ( localize(14499, "Color for the 'Errored' icon in the test explorer.")));
|
|
17
|
+
const testingColorIconFailed = registerColor("testing.iconFailed", listErrorForeground, ( localize(14580, "Color for the 'failed' icon in the test explorer.")));
|
|
18
|
+
const testingColorIconErrored = registerColor("testing.iconErrored", listErrorForeground, ( localize(14581, "Color for the 'Errored' icon in the test explorer.")));
|
|
29
19
|
const testingColorIconPassed = registerColor("testing.iconPassed", {
|
|
30
20
|
dark: "#73c991",
|
|
31
21
|
light: "#73c991",
|
|
32
22
|
hcDark: "#73c991",
|
|
33
23
|
hcLight: "#007100"
|
|
34
|
-
}, ( localize(
|
|
35
|
-
const testingColorRunAction = registerColor("testing.runAction", testingColorIconPassed, ( localize(
|
|
36
|
-
const testingColorIconQueued = registerColor("testing.iconQueued",
|
|
37
|
-
const testingColorIconUnset = registerColor("testing.iconUnset", "#848484", ( localize(
|
|
38
|
-
const testingColorIconSkipped = registerColor("testing.iconSkipped", "#848484", ( localize(
|
|
24
|
+
}, ( localize(14582, "Color for the 'passed' icon in the test explorer.")));
|
|
25
|
+
const testingColorRunAction = registerColor("testing.runAction", testingColorIconPassed, ( localize(14583, "Color for 'run' icons in the editor.")));
|
|
26
|
+
const testingColorIconQueued = registerColor("testing.iconQueued", listWarningForeground, ( localize(14584, "Color for the 'Queued' icon in the test explorer.")));
|
|
27
|
+
const testingColorIconUnset = registerColor("testing.iconUnset", "#848484", ( localize(14585, "Color for the 'Unset' icon in the test explorer.")));
|
|
28
|
+
const testingColorIconSkipped = registerColor("testing.iconSkipped", "#848484", ( localize(14586, "Color for the 'Skipped' icon in the test explorer.")));
|
|
39
29
|
const testingPeekBorder = registerColor("testing.peekBorder", {
|
|
40
30
|
dark: editorErrorForeground,
|
|
41
31
|
light: editorErrorForeground,
|
|
42
32
|
hcDark: contrastBorder,
|
|
43
33
|
hcLight: contrastBorder
|
|
44
|
-
}, ( localize(
|
|
34
|
+
}, ( localize(14587, "Color of the peek view borders and arrow.")));
|
|
45
35
|
const testingMessagePeekBorder = registerColor("testing.messagePeekBorder", {
|
|
46
36
|
dark: editorInfoForeground,
|
|
47
37
|
light: editorInfoForeground,
|
|
48
38
|
hcDark: contrastBorder,
|
|
49
39
|
hcLight: contrastBorder
|
|
50
40
|
}, ( localize(
|
|
51
|
-
|
|
41
|
+
14588,
|
|
52
42
|
"Color of the peek view borders and arrow when peeking a logged message."
|
|
53
43
|
)));
|
|
54
44
|
const testingPeekHeaderBackground = registerColor("testing.peekHeaderBackground", {
|
|
@@ -56,14 +46,14 @@ const testingPeekHeaderBackground = registerColor("testing.peekHeaderBackground"
|
|
|
56
46
|
light: ( transparent(editorErrorForeground, 0.1)),
|
|
57
47
|
hcDark: null,
|
|
58
48
|
hcLight: null
|
|
59
|
-
}, ( localize(
|
|
49
|
+
}, ( localize(14587, "Color of the peek view borders and arrow.")));
|
|
60
50
|
const testingPeekMessageHeaderBackground = registerColor("testing.messagePeekHeaderBackground", {
|
|
61
51
|
dark: ( transparent(editorInfoForeground, 0.1)),
|
|
62
52
|
light: ( transparent(editorInfoForeground, 0.1)),
|
|
63
53
|
hcDark: null,
|
|
64
54
|
hcLight: null
|
|
65
55
|
}, ( localize(
|
|
66
|
-
|
|
56
|
+
14589,
|
|
67
57
|
"Color of the peek view borders and arrow when peeking a logged message."
|
|
68
58
|
)));
|
|
69
59
|
const testingCoveredBackground = registerColor("testing.coveredBackground", {
|
|
@@ -71,66 +61,66 @@ const testingCoveredBackground = registerColor("testing.coveredBackground", {
|
|
|
71
61
|
light: diffInserted,
|
|
72
62
|
hcDark: null,
|
|
73
63
|
hcLight: null
|
|
74
|
-
}, ( localize(
|
|
64
|
+
}, ( localize(14590, "Background color of text that was covered.")));
|
|
75
65
|
const testingCoveredBorder = registerColor("testing.coveredBorder", {
|
|
76
66
|
dark: ( transparent(testingCoveredBackground, 0.75)),
|
|
77
67
|
light: ( transparent(testingCoveredBackground, 0.75)),
|
|
78
68
|
hcDark: contrastBorder,
|
|
79
69
|
hcLight: contrastBorder
|
|
80
|
-
}, ( localize(
|
|
70
|
+
}, ( localize(14591, "Border color of text that was covered.")));
|
|
81
71
|
registerColor("testing.coveredGutterBackground", {
|
|
82
72
|
dark: ( transparent(diffInserted, 0.6)),
|
|
83
73
|
light: ( transparent(diffInserted, 0.6)),
|
|
84
74
|
hcDark: chartsGreen,
|
|
85
75
|
hcLight: chartsGreen
|
|
86
|
-
}, ( localize(
|
|
76
|
+
}, ( localize(14592, "Gutter color of regions where code was covered.")));
|
|
87
77
|
registerColor("testing.uncoveredBranchBackground", {
|
|
88
78
|
dark: opaque(( transparent(diffRemoved, 2)), editorBackground),
|
|
89
79
|
light: opaque(( transparent(diffRemoved, 2)), editorBackground),
|
|
90
80
|
hcDark: null,
|
|
91
81
|
hcLight: null
|
|
92
|
-
}, ( localize(
|
|
82
|
+
}, ( localize(14593, "Background of the widget shown for an uncovered branch.")));
|
|
93
83
|
const testingUncoveredBackground = registerColor("testing.uncoveredBackground", {
|
|
94
84
|
dark: diffRemoved,
|
|
95
85
|
light: diffRemoved,
|
|
96
86
|
hcDark: null,
|
|
97
87
|
hcLight: null
|
|
98
|
-
}, ( localize(
|
|
88
|
+
}, ( localize(14594, "Background color of text that was not covered.")));
|
|
99
89
|
const testingUncoveredBorder = registerColor("testing.uncoveredBorder", {
|
|
100
90
|
dark: ( transparent(testingUncoveredBackground, 0.75)),
|
|
101
91
|
light: ( transparent(testingUncoveredBackground, 0.75)),
|
|
102
92
|
hcDark: contrastBorder,
|
|
103
93
|
hcLight: contrastBorder
|
|
104
|
-
}, ( localize(
|
|
94
|
+
}, ( localize(14595, "Border color of text that was not covered.")));
|
|
105
95
|
registerColor("testing.uncoveredGutterBackground", {
|
|
106
96
|
dark: ( transparent(diffRemoved, 1.5)),
|
|
107
97
|
light: ( transparent(diffRemoved, 1.5)),
|
|
108
98
|
hcDark: chartsRed,
|
|
109
99
|
hcLight: chartsRed
|
|
110
|
-
}, ( localize(
|
|
111
|
-
registerColor("testing.coverCountBadgeBackground", badgeBackground, ( localize(
|
|
112
|
-
registerColor("testing.coverCountBadgeForeground", badgeForeground, ( localize(
|
|
100
|
+
}, ( localize(14596, "Gutter color of regions where code not covered.")));
|
|
101
|
+
registerColor("testing.coverCountBadgeBackground", badgeBackground, ( localize(14597, "Background for the badge indicating execution count")));
|
|
102
|
+
registerColor("testing.coverCountBadgeForeground", badgeForeground, ( localize(14598, "Foreground for the badge indicating execution count")));
|
|
113
103
|
const messageBadgeBackground = registerColor(
|
|
114
104
|
"testing.message.error.badgeBackground",
|
|
115
105
|
activityErrorBadgeBackground,
|
|
116
106
|
( localize(
|
|
117
|
-
|
|
107
|
+
14599,
|
|
118
108
|
"Background color of test error messages shown inline in the editor."
|
|
119
109
|
))
|
|
120
110
|
);
|
|
121
111
|
registerColor(
|
|
122
112
|
"testing.message.error.badgeBorder",
|
|
123
113
|
messageBadgeBackground,
|
|
124
|
-
( localize(
|
|
114
|
+
( localize(14600, "Border color of test error messages shown inline in the editor."))
|
|
125
115
|
);
|
|
126
116
|
registerColor(
|
|
127
117
|
"testing.message.error.badgeForeground",
|
|
128
118
|
activityErrorBadgeForeground,
|
|
129
|
-
( localize(
|
|
119
|
+
( localize(14601, "Text color of test error messages shown inline in the editor."))
|
|
130
120
|
);
|
|
131
|
-
registerColor("testing.message.error.lineBackground", null, ( localize(
|
|
132
|
-
registerColor("testing.message.info.decorationForeground", ( transparent(editorForeground, 0.5)), ( localize(
|
|
133
|
-
registerColor("testing.message.info.lineBackground", null, ( localize(
|
|
121
|
+
registerColor("testing.message.error.lineBackground", null, ( localize(14602, "Margin color beside error messages shown inline in the editor.")));
|
|
122
|
+
registerColor("testing.message.info.decorationForeground", ( transparent(editorForeground, 0.5)), ( localize(14603, "Text color of test info messages shown inline in the editor.")));
|
|
123
|
+
registerColor("testing.message.info.lineBackground", null, ( localize(14604, "Margin color beside info messages shown inline in the editor.")));
|
|
134
124
|
const testStatesToIconColors = {
|
|
135
125
|
[TestResultState.Errored]: testingColorIconErrored,
|
|
136
126
|
[TestResultState.Failed]: testingColorIconFailed,
|
|
@@ -139,12 +129,12 @@ const testStatesToIconColors = {
|
|
|
139
129
|
[TestResultState.Unset]: testingColorIconUnset,
|
|
140
130
|
[TestResultState.Skipped]: testingColorIconSkipped
|
|
141
131
|
};
|
|
142
|
-
const testingRetiredColorIconErrored = registerColor("testing.iconErrored.retired", ( transparent(testingColorIconErrored, 0.7)), ( localize(
|
|
143
|
-
const testingRetiredColorIconFailed = registerColor("testing.iconFailed.retired", ( transparent(testingColorIconFailed, 0.7)), ( localize(
|
|
144
|
-
const testingRetiredColorIconPassed = registerColor("testing.iconPassed.retired", ( transparent(testingColorIconPassed, 0.7)), ( localize(
|
|
145
|
-
const testingRetiredColorIconQueued = registerColor("testing.iconQueued.retired", ( transparent(testingColorIconQueued, 0.7)), ( localize(
|
|
146
|
-
const testingRetiredColorIconUnset = registerColor("testing.iconUnset.retired", ( transparent(testingColorIconUnset, 0.7)), ( localize(
|
|
147
|
-
const testingRetiredColorIconSkipped = registerColor("testing.iconSkipped.retired", ( transparent(testingColorIconSkipped, 0.7)), ( localize(
|
|
132
|
+
const testingRetiredColorIconErrored = registerColor("testing.iconErrored.retired", ( transparent(testingColorIconErrored, 0.7)), ( localize(14605, "Retired color for the 'Errored' icon in the test explorer.")));
|
|
133
|
+
const testingRetiredColorIconFailed = registerColor("testing.iconFailed.retired", ( transparent(testingColorIconFailed, 0.7)), ( localize(14606, "Retired color for the 'failed' icon in the test explorer.")));
|
|
134
|
+
const testingRetiredColorIconPassed = registerColor("testing.iconPassed.retired", ( transparent(testingColorIconPassed, 0.7)), ( localize(14607, "Retired color for the 'passed' icon in the test explorer.")));
|
|
135
|
+
const testingRetiredColorIconQueued = registerColor("testing.iconQueued.retired", ( transparent(testingColorIconQueued, 0.7)), ( localize(14608, "Retired color for the 'Queued' icon in the test explorer.")));
|
|
136
|
+
const testingRetiredColorIconUnset = registerColor("testing.iconUnset.retired", ( transparent(testingColorIconUnset, 0.7)), ( localize(14609, "Retired color for the 'Unset' icon in the test explorer.")));
|
|
137
|
+
const testingRetiredColorIconSkipped = registerColor("testing.iconSkipped.retired", ( transparent(testingColorIconSkipped, 0.7)), ( localize(14610, "Retired color for the 'Skipped' icon in the test explorer.")));
|
|
148
138
|
const testStatesToRetiredIconColors = {
|
|
149
139
|
[TestResultState.Errored]: testingRetiredColorIconErrored,
|
|
150
140
|
[TestResultState.Failed]: testingRetiredColorIconFailed,
|
|
@@ -64,46 +64,46 @@ var TestingResultsViewLayout;
|
|
|
64
64
|
const testingConfiguration = {
|
|
65
65
|
id: "testing",
|
|
66
66
|
order: 21,
|
|
67
|
-
title: ( localize(
|
|
67
|
+
title: ( localize(14611, "Testing")),
|
|
68
68
|
type: "object",
|
|
69
69
|
properties: {
|
|
70
70
|
[TestingConfigKeys.AutoOpenPeekView]: {
|
|
71
|
-
description: ( localize(
|
|
71
|
+
description: ( localize(14612, "Configures when the error Peek view is automatically opened.")),
|
|
72
72
|
enum: [
|
|
73
73
|
AutoOpenPeekViewWhen.FailureAnywhere,
|
|
74
74
|
AutoOpenPeekViewWhen.FailureVisible,
|
|
75
75
|
AutoOpenPeekViewWhen.Never
|
|
76
76
|
],
|
|
77
77
|
default: AutoOpenPeekViewWhen.Never,
|
|
78
|
-
enumDescriptions: [( localize(
|
|
78
|
+
enumDescriptions: [( localize(14613, "Open automatically no matter where the failure is.")), ( localize(14614, "Open automatically when a test fails in a visible document.")), ( localize(14615, "Never automatically open."))]
|
|
79
79
|
},
|
|
80
80
|
[TestingConfigKeys.ShowAllMessages]: {
|
|
81
|
-
description: ( localize(
|
|
81
|
+
description: ( localize(14616, "Controls whether to show messages from all test runs.")),
|
|
82
82
|
type: "boolean",
|
|
83
83
|
default: false
|
|
84
84
|
},
|
|
85
85
|
[TestingConfigKeys.AutoOpenPeekViewDuringContinuousRun]: {
|
|
86
86
|
description: ( localize(
|
|
87
|
-
|
|
87
|
+
14617,
|
|
88
88
|
"Controls whether to automatically open the Peek view during continuous run mode."
|
|
89
89
|
)),
|
|
90
90
|
type: "boolean",
|
|
91
91
|
default: false
|
|
92
92
|
},
|
|
93
93
|
[TestingConfigKeys.CountBadge]: {
|
|
94
|
-
description: ( localize(
|
|
94
|
+
description: ( localize(14618, "Controls the count badge on the Testing icon on the Activity Bar.")),
|
|
95
95
|
enum: [
|
|
96
96
|
TestingCountBadge.Failed,
|
|
97
97
|
TestingCountBadge.Off,
|
|
98
98
|
TestingCountBadge.Passed,
|
|
99
99
|
TestingCountBadge.Skipped
|
|
100
100
|
],
|
|
101
|
-
enumDescriptions: [( localize(
|
|
101
|
+
enumDescriptions: [( localize(14619, "Show the number of failed tests")), ( localize(14620, "Disable the testing count badge")), ( localize(14621, "Show the number of passed tests")), ( localize(14622, "Show the number of skipped tests"))],
|
|
102
102
|
default: TestingCountBadge.Failed
|
|
103
103
|
},
|
|
104
104
|
[TestingConfigKeys.FollowRunningTest]: {
|
|
105
105
|
description: ( localize(
|
|
106
|
-
|
|
106
|
+
14623,
|
|
107
107
|
"Controls whether the running test should be followed in the Test Explorer view."
|
|
108
108
|
)),
|
|
109
109
|
type: "boolean",
|
|
@@ -111,7 +111,7 @@ const testingConfiguration = {
|
|
|
111
111
|
},
|
|
112
112
|
[TestingConfigKeys.DefaultGutterClickAction]: {
|
|
113
113
|
description: ( localize(
|
|
114
|
-
|
|
114
|
+
14624,
|
|
115
115
|
"Controls the action to take when left-clicking on a test decoration in the gutter."
|
|
116
116
|
)),
|
|
117
117
|
enum: [
|
|
@@ -120,16 +120,16 @@ const testingConfiguration = {
|
|
|
120
120
|
DefaultGutterClickAction.Coverage,
|
|
121
121
|
DefaultGutterClickAction.ContextMenu
|
|
122
122
|
],
|
|
123
|
-
enumDescriptions: [( localize(
|
|
123
|
+
enumDescriptions: [( localize(14625, "Run the test.")), ( localize(14626, "Debug the test.")), ( localize(14627, "Run the test with coverage.")), ( localize(14628, "Open the context menu for more options."))],
|
|
124
124
|
default: DefaultGutterClickAction.Run
|
|
125
125
|
},
|
|
126
126
|
[TestingConfigKeys.GutterEnabled]: {
|
|
127
|
-
description: ( localize(
|
|
127
|
+
description: ( localize(14629, "Controls whether test decorations are shown in the editor gutter.")),
|
|
128
128
|
type: "boolean",
|
|
129
129
|
default: true
|
|
130
130
|
},
|
|
131
131
|
[TestingConfigKeys.SaveBeforeTest]: {
|
|
132
|
-
description: ( localize(
|
|
132
|
+
description: ( localize(14630, "Control whether save all dirty editors before running a test.")),
|
|
133
133
|
type: "boolean",
|
|
134
134
|
default: true
|
|
135
135
|
},
|
|
@@ -140,13 +140,13 @@ const testingConfiguration = {
|
|
|
140
140
|
AutoOpenTesting.OpenOnTestFailure,
|
|
141
141
|
AutoOpenTesting.OpenExplorerOnTestStart
|
|
142
142
|
],
|
|
143
|
-
enumDescriptions: [( localize(
|
|
143
|
+
enumDescriptions: [( localize(14631, "Never automatically open the testing views")), ( localize(14632, "Open the test results view when tests start")), ( localize(14633, "Open the test result view on any test failure")), ( localize(14634, "Open the test explorer when tests start"))],
|
|
144
144
|
default: "openOnTestStart",
|
|
145
|
-
description: ( localize(
|
|
145
|
+
description: ( localize(14635, "Controls when the testing view should open."))
|
|
146
146
|
},
|
|
147
147
|
[TestingConfigKeys.AlwaysRevealTestOnStateChange]: {
|
|
148
148
|
markdownDescription: ( localize(
|
|
149
|
-
|
|
149
|
+
14636,
|
|
150
150
|
"Always reveal the executed test when {0} is on. If this setting is turned off, only failed tests will be revealed.",
|
|
151
151
|
"`#testing.followRunningTest#`"
|
|
152
152
|
)),
|
|
@@ -154,13 +154,13 @@ const testingConfiguration = {
|
|
|
154
154
|
default: false
|
|
155
155
|
},
|
|
156
156
|
[TestingConfigKeys.ShowCoverageInExplorer]: {
|
|
157
|
-
description: ( localize(
|
|
157
|
+
description: ( localize(14637, "Whether test coverage should be down in the File Explorer view.")),
|
|
158
158
|
type: "boolean",
|
|
159
159
|
default: true
|
|
160
160
|
},
|
|
161
161
|
[TestingConfigKeys.CoveragePercent]: {
|
|
162
162
|
markdownDescription: ( localize(
|
|
163
|
-
|
|
163
|
+
14638,
|
|
164
164
|
"Configures what percentage is displayed by default for test coverage."
|
|
165
165
|
)),
|
|
166
166
|
default: TestingDisplayedCoveragePercent.TotalCoverage,
|
|
@@ -170,12 +170,12 @@ const testingConfiguration = {
|
|
|
170
170
|
TestingDisplayedCoveragePercent.Minimum
|
|
171
171
|
],
|
|
172
172
|
enumDescriptions: [( localize(
|
|
173
|
-
|
|
173
|
+
14639,
|
|
174
174
|
"A calculation of the combined statement, function, and branch coverage."
|
|
175
|
-
)), ( localize(
|
|
175
|
+
)), ( localize(14640, "The statement coverage.")), ( localize(14641, "The minimum of statement, function, and branch coverage."))]
|
|
176
176
|
},
|
|
177
177
|
[TestingConfigKeys.CoverageBarThresholds]: {
|
|
178
|
-
markdownDescription: ( localize(
|
|
178
|
+
markdownDescription: ( localize(14642, "Configures the colors used for percentages in test coverage bars.")),
|
|
179
179
|
default: {
|
|
180
180
|
red: 0,
|
|
181
181
|
yellow: 60,
|
|
@@ -203,18 +203,18 @@ const testingConfiguration = {
|
|
|
203
203
|
}
|
|
204
204
|
},
|
|
205
205
|
[TestingConfigKeys.CoverageToolbarEnabled]: {
|
|
206
|
-
description: ( localize(
|
|
206
|
+
description: ( localize(14643, "Controls whether the coverage toolbar is shown in the editor.")),
|
|
207
207
|
type: "boolean",
|
|
208
208
|
default: false
|
|
209
209
|
},
|
|
210
210
|
[TestingConfigKeys.ResultsViewLayout]: {
|
|
211
|
-
description: ( localize(
|
|
211
|
+
description: ( localize(14644, "Controls the layout of the Test Results view.")),
|
|
212
212
|
enum: [TestingResultsViewLayout.TreeRight, TestingResultsViewLayout.TreeLeft],
|
|
213
213
|
enumDescriptions: [( localize(
|
|
214
|
-
|
|
214
|
+
14645,
|
|
215
215
|
"Show the test run tree on the right side with details on the left."
|
|
216
216
|
)), ( localize(
|
|
217
|
-
|
|
217
|
+
14646,
|
|
218
218
|
"Show the test run tree on the left side with details on the right."
|
|
219
219
|
))],
|
|
220
220
|
default: TestingResultsViewLayout.TreeRight
|
|
@@ -164,7 +164,7 @@ let TestService = class TestService extends Disposable {
|
|
|
164
164
|
req.exclude = [...this.excluded.all];
|
|
165
165
|
}
|
|
166
166
|
const trust = await this.workspaceTrustRequestService.requestWorkspaceTrust({
|
|
167
|
-
message: ( localize(
|
|
167
|
+
message: ( localize(14660, "Running tests may execute code in your workspace."))
|
|
168
168
|
});
|
|
169
169
|
if (!trust) {
|
|
170
170
|
return;
|
|
@@ -179,7 +179,7 @@ let TestService = class TestService extends Disposable {
|
|
|
179
179
|
}))), token).then(result => {
|
|
180
180
|
const errs = ( result.map(r => r.error)).filter(isDefined);
|
|
181
181
|
if (errs.length) {
|
|
182
|
-
this.notificationService.error(( localize(
|
|
182
|
+
this.notificationService.error(( localize(14661, "An error occurred attempting to run tests: {0}", errs.join(" "))));
|
|
183
183
|
}
|
|
184
184
|
})
|
|
185
185
|
));
|
|
@@ -191,7 +191,7 @@ let TestService = class TestService extends Disposable {
|
|
|
191
191
|
}
|
|
192
192
|
const result = this.testResults.createLiveResult(req);
|
|
193
193
|
const trust = await this.workspaceTrustRequestService.requestWorkspaceTrust({
|
|
194
|
-
message: ( localize(
|
|
194
|
+
message: ( localize(14660, "Running tests may execute code in your workspace."))
|
|
195
195
|
});
|
|
196
196
|
if (!trust) {
|
|
197
197
|
result.markComplete();
|
|
@@ -211,7 +211,7 @@ let TestService = class TestService extends Disposable {
|
|
|
211
211
|
}))), cancelSource.token).then(result => {
|
|
212
212
|
const errs = ( result.map(r => r.error)).filter(isDefined);
|
|
213
213
|
if (errs.length) {
|
|
214
|
-
this.notificationService.error(( localize(
|
|
214
|
+
this.notificationService.error(( localize(14661, "An error occurred attempting to run tests: {0}", errs.join(" "))));
|
|
215
215
|
}
|
|
216
216
|
})
|
|
217
217
|
));
|
|
@@ -84,7 +84,7 @@ let RunTestTool = class RunTestTool {
|
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
-
userDescription: ( localize(
|
|
87
|
+
userDescription: ( localize(14665, "Run unit tests (optionally with coverage)")),
|
|
88
88
|
source: ToolDataSource.Internal,
|
|
89
89
|
tags: [
|
|
90
90
|
"vscode_editing_with_tests",
|
|
@@ -123,11 +123,11 @@ let RunTestTool = class RunTestTool {
|
|
|
123
123
|
kind: "text",
|
|
124
124
|
value: "No tests found in the files. Ensure the correct absolute paths are passed to the tool."
|
|
125
125
|
}],
|
|
126
|
-
toolResultError: ( localize(
|
|
126
|
+
toolResultError: ( localize(14666, "No tests found in the files"))
|
|
127
127
|
};
|
|
128
128
|
}
|
|
129
129
|
progress.report({
|
|
130
|
-
message: ( localize(
|
|
130
|
+
message: ( localize(14667, "Starting test run..."))
|
|
131
131
|
});
|
|
132
132
|
if (group === TestRunProfileBitset.Coverage) {
|
|
133
133
|
if (!( testCases.some(
|
|
@@ -144,7 +144,7 @@ let RunTestTool = class RunTestTool {
|
|
|
144
144
|
value: "No test run was started. Instruct the user to ensure their test runner is correctly configured"
|
|
145
145
|
}],
|
|
146
146
|
toolResultError: ( localize(
|
|
147
|
-
|
|
147
|
+
14668,
|
|
148
148
|
"No test run was started. This may be an issue with your test runner or extension."
|
|
149
149
|
))
|
|
150
150
|
};
|
|
@@ -155,9 +155,9 @@ let RunTestTool = class RunTestTool {
|
|
|
155
155
|
return {
|
|
156
156
|
content: [{
|
|
157
157
|
kind: "text",
|
|
158
|
-
value: ( localize(
|
|
158
|
+
value: ( localize(14669, "Test run was cancelled."))
|
|
159
159
|
}],
|
|
160
|
-
toolResultMessage: ( localize(
|
|
160
|
+
toolResultMessage: ( localize(14669, "Test run was cancelled."))
|
|
161
161
|
};
|
|
162
162
|
}
|
|
163
163
|
const summary = await buildTestRunSummary(result, mode, coverageFiles);
|
|
@@ -228,7 +228,7 @@ let RunTestTool = class RunTestTool {
|
|
|
228
228
|
return tests;
|
|
229
229
|
}
|
|
230
230
|
progress.report({
|
|
231
|
-
message: ( localize(
|
|
231
|
+
message: ( localize(14670, "Filtering tests..."))
|
|
232
232
|
});
|
|
233
233
|
const testNames = ( params.testNames.map(t => t.toLowerCase().trim()));
|
|
234
234
|
const filtered = [];
|
|
@@ -257,7 +257,7 @@ let RunTestTool = class RunTestTool {
|
|
|
257
257
|
return [...this._testService.collection.rootItems];
|
|
258
258
|
}
|
|
259
259
|
progress.report({
|
|
260
|
-
message: ( localize(
|
|
260
|
+
message: ( localize(14671, "Discovering tests..."))
|
|
261
261
|
});
|
|
262
262
|
const firstWorkspaceFolder = this._workspaceContextService.getWorkspace().folders.at(0)?.uri;
|
|
263
263
|
const uris = ( params.files.map(f => {
|
|
@@ -281,13 +281,13 @@ let RunTestTool = class RunTestTool {
|
|
|
281
281
|
}
|
|
282
282
|
prepareToolInvocation(context, token) {
|
|
283
283
|
const params = context.parameters;
|
|
284
|
-
const title = ( localize(
|
|
284
|
+
const title = ( localize(14672, "Allow test run?"));
|
|
285
285
|
const inFiles = params.files?.map(f => "`" + basename(f) + "`");
|
|
286
286
|
return Promise.resolve({
|
|
287
|
-
invocationMessage: ( localize(
|
|
287
|
+
invocationMessage: ( localize(14673, "Running tests...")),
|
|
288
288
|
confirmationMessages: {
|
|
289
289
|
title,
|
|
290
|
-
message: inFiles?.length ? ( new MarkdownString()).appendMarkdown(( localize(
|
|
290
|
+
message: inFiles?.length ? ( new MarkdownString()).appendMarkdown(( localize(14674, "The model wants to run tests in {0}.", inFiles.join(", ")))) : ( localize(14675, "The model wants to run all tests.")),
|
|
291
291
|
allowAutoConfirm: true
|
|
292
292
|
}
|
|
293
293
|
});
|
|
@@ -59,7 +59,7 @@ let TestingContentProvider = class TestingContentProvider {
|
|
|
59
59
|
return;
|
|
60
60
|
}
|
|
61
61
|
if (!hadContent) {
|
|
62
|
-
append(( localize(
|
|
62
|
+
append(( localize(14676, "The test run did not record any output.")));
|
|
63
63
|
dispose.dispose();
|
|
64
64
|
}
|
|
65
65
|
});
|