@@ -20,11 +20,13 @@ import {
2020type InclusionTestArgs = {
2121 docUri : vscode . Uri ;
2222 expected : vscode . Diagnostic [ ] ;
23+ timeoutMs ?: number ;
2324} ;
2425
2526export async function testSyntaxValidation ( {
2627 docUri,
2728 expected,
29+ timeoutMs,
2830} : InclusionTestArgs ) {
2931 await eventually (
3032 ( ) =>
@@ -66,6 +68,7 @@ export async function testSyntaxValidation({
6668 reject ( e ) ;
6769 }
6870 } ) ,
71+ timeoutMs ,
6972 ) ;
7073}
7174
@@ -74,7 +77,8 @@ suite('Syntax validation spec', () => {
7477 await toggleLinting ( true ) ;
7578 } ) ;
7679
77- test ( 'Suggests replacements for deprecated functions/procedures' , async ( ) => {
80+ test ( 'Suggests replacements for deprecated functions/procedures' , async function ( ) {
81+ this . timeout ( 60000 ) ;
7882 const textFile = 'deprecated-by.cypher' ;
7983 const docUri = getDocumentUri ( textFile ) ;
8084
@@ -100,10 +104,12 @@ suite('Syntax validation spec', () => {
100104 vscode . DiagnosticSeverity . Warning ,
101105 ) ,
102106 ] ,
107+ timeoutMs : 40000 ,
103108 } ) ;
104109 } ) ;
105110
106- test ( 'Relints when database connected / disconnected' , async ( ) => {
111+ test ( 'Relints when database connected / disconnected' , async function ( ) {
112+ this . timeout ( 60000 ) ;
107113 const textFile = 'deprecated-by.cypher' ;
108114 const docUri = getDocumentUri ( textFile ) ;
109115
@@ -125,16 +131,19 @@ suite('Syntax validation spec', () => {
125131 await testSyntaxValidation ( {
126132 docUri,
127133 expected : deprecationErrors ,
134+ timeoutMs : 40000 ,
128135 } ) ;
129136 await disconnectDefault ( ) ;
130137 await testSyntaxValidation ( {
131138 docUri,
132139 expected : [ ] ,
140+ timeoutMs : 40000 ,
133141 } ) ;
134142 await connectDefault ( ) ;
135143 await testSyntaxValidation ( {
136144 docUri,
137145 expected : deprecationErrors ,
146+ timeoutMs : 40000 ,
138147 } ) ;
139148 } ) ;
140149
@@ -342,7 +351,8 @@ suite('Syntax validation spec', () => {
342351 } ) ;
343352 } ) ;
344353
345- test ( 'Linting can be disabled with the config option' , async ( ) => {
354+ test ( 'Linting can be disabled with the config option' , async function ( ) {
355+ this . timeout ( 60000 ) ;
346356 const textFile = 'deprecated-by.cypher' ;
347357 const docUri = getDocumentUri ( textFile ) ;
348358
@@ -368,12 +378,14 @@ suite('Syntax validation spec', () => {
368378 vscode . DiagnosticSeverity . Warning ,
369379 ) ,
370380 ] ,
381+ timeoutMs : 40000 ,
371382 } ) ;
372383
373384 await toggleLinting ( false ) ;
374385 await testSyntaxValidation ( {
375386 docUri,
376387 expected : [ ] ,
388+ timeoutMs : 40000 ,
377389 } ) ;
378390 } ) ;
379391} ) ;
0 commit comments