File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed
Extension/test/scenarios/SimpleCppProject/tests Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change
1
+ /* --------------------------------------------------------------------------------------------
2
+ * Copyright (c) Microsoft Corporation. All Rights Reserved.
3
+ * See 'LICENSE' in the project root for license information.
4
+ * ------------------------------------------------------------------------------------------ */
5
+ import { equal } from 'assert' ;
6
+ import { suite } from 'mocha' ;
7
+ import * as vscode from 'vscode' ;
8
+ import * as util from '../../../../src/common' ;
9
+ import { isWindows } from "../../../../src/constants" ;
10
+
11
+ suite ( "set developer environment" , ( ) => {
12
+ if ( isWindows ) {
13
+ test ( "set developer environment (Windows)" , async ( ) => {
14
+ const promise = vscode . commands . executeCommand ( 'C_Cpp.SetDevEnvironment' , 'test' ) ;
15
+ const timer = setInterval ( ( ) => {
16
+ void vscode . commands . executeCommand ( 'workbench.action.acceptSelectedQuickOpenItem' ) ;
17
+ } , 1000 ) ;
18
+ await promise ;
19
+ clearInterval ( timer ) ;
20
+ equal ( util . hasMsvcEnvironment ( ) , true , "MSVC environment not set correctly." ) ;
21
+ } ) ;
22
+ } else {
23
+ test ( "set developer environment (Linux/macOS)" , ( ) => {
24
+ } ) ;
25
+ }
26
+ } ) ;
You can’t perform that action at this time.
0 commit comments