@@ -125,7 +125,6 @@ suite('Extension Test Suite', () => {
125
125
vscode . window . showInformationMessage ( 'Start all tests.' ) ;
126
126
127
127
suiteSetup ( async ( ) => {
128
- const tmpdir = path . join ( getWorkspaceRoot ( ) . uri . fsPath , 'tmp' ) ;
129
128
await deleteWorkspaceFiles ( [
130
129
joinUri ( getWorkspaceRoot ( ) . uri , '.vscode' ) ,
131
130
joinUri ( getWorkspaceRoot ( ) . uri , 'bin' , process . platform === 'win32' ? 'ghcup' : '.ghcup' , 'cache' ) ,
@@ -137,17 +136,10 @@ suite('Extension Test Suite', () => {
137
136
await getHaskellConfig ( ) . update ( 'releasesDownloadStoragePath' , path . normalize ( getWorkspaceFile ( 'bin' ) . fsPath ) ) ;
138
137
await getHaskellConfig ( ) . update ( 'serverEnvironment' , {
139
138
XDG_CACHE_HOME : path . normalize ( getWorkspaceFile ( 'cache-test' ) . fsPath ) ,
140
- TMPDIR : tmpdir ,
141
- TMP : tmpdir ,
142
139
} ) ;
143
- fs . mkdirSync ( tmpdir , { recursive : true } ) ;
144
140
const contents = new TextEncoder ( ) . encode ( 'main = putStrLn "hi vscode tests"' ) ;
145
141
await vscode . workspace . fs . writeFile ( getWorkspaceFile ( 'Main.hs' ) , contents ) ;
146
142
147
- const pred = ( uri : vscode . Uri ) => ! [ 'download' , 'gz' , 'zip' ] . includes ( path . extname ( uri . fsPath ) ) ;
148
- // Setting up watchers before actual tests start, to ensure we will got the created event
149
- filesCreated . set ( 'wrapper' , existsWorkspaceFile ( `tmp/ghcup-*/haskell-language-server-wrapper*` , pred ) ) ;
150
- filesCreated . set ( 'server' , existsWorkspaceFile ( `tmp/ghcup-*/haskell-language-server-[1-9]*` , pred ) ) ;
151
143
filesCreated . set ( 'log' , existsWorkspaceFile ( 'hls.log' ) ) ;
152
144
filesCreated . set ( 'cache' , existsWorkspaceFile ( 'cache-test' ) ) ;
153
145
} ) ;
@@ -166,20 +158,6 @@ suite('Extension Test Suite', () => {
166
158
assert . ok ( await withTimeout ( 90 , filesCreated . get ( 'log' ) ! ) , 'Extension log not created in 30 seconds' ) ;
167
159
} ) ;
168
160
169
- test ( 'HLS executables should be downloaded' , async ( ) => {
170
- await vscode . workspace . openTextDocument ( getWorkspaceFile ( 'Main.hs' ) ) ;
171
- console . log ( 'Testing wrapper' ) ;
172
- assert . ok (
173
- await withTimeout ( 90 , filesCreated . get ( 'wrapper' ) ! ) ,
174
- 'The wrapper executable was not downloaded in 90 seconds'
175
- ) ;
176
- console . log ( 'Testing server' ) ;
177
- assert . ok (
178
- await withTimeout ( 90 , filesCreated . get ( 'server' ) ! ) ,
179
- 'The server executable was not downloaded in 90 seconds'
180
- ) ;
181
- } ) ;
182
-
183
161
test ( 'Extension log should have server output' , async ( ) => {
184
162
await vscode . workspace . openTextDocument ( getWorkspaceFile ( 'Main.hs' ) ) ;
185
163
await delay ( 20 ) ;
0 commit comments