3838 ALSLanguageClient ,
3939 ALSSettings ,
4040 assertEqual ,
41- awaitIndexingEnd ,
4241 test ,
4342)
4443
@@ -68,18 +67,18 @@ async def test1(lsp: ALSLanguageClient) -> None:
6867 )
6968 # Because no project file was set, we need a didOpen to load the project
7069 lsp .didOpenVirtual ()
71- await awaitIndexingEnd (lsp )
70+ await lsp . awaitIndexingEnd ()
7271 assertEqual (await lsp .getObjDirBasename (), "value-from-init" )
7372
7473 # Now let's change the settings
7574 lsp .didChangeConfig ({"scenarioVariables" : {"Var" : "new-value" }})
76- await awaitIndexingEnd (lsp )
75+ await lsp . awaitIndexingEnd ()
7776 assertEqual (await lsp .getObjDirBasename (), "new-value" )
7877
7978 # Now we send a null value to revert to the base config which should be the config
8079 # file, not the initialize request.
8180 lsp .didChangeConfig ({"scenarioVariables" : None })
82- await awaitIndexingEnd (lsp )
81+ await lsp . awaitIndexingEnd ()
8382 assertEqual (await lsp .getObjDirBasename (), "value-from-config-file" )
8483
8584
@@ -99,17 +98,17 @@ async def test2(lsp: ALSLanguageClient) -> None:
9998 )
10099 # Because no project file was set, we need a didOpen to load the project
101100 lsp .didOpenVirtual ()
102- await awaitIndexingEnd (lsp )
101+ await lsp . awaitIndexingEnd ()
103102 assertEqual (await lsp .getObjDirBasename (), "value-from-init" )
104103
105104 # Now let's change the settings and revert back to see if we revert to the right
106105 # value.
107106 lsp .didChangeConfig ({"scenarioVariables" : {"Var" : "new-value" }})
108- await awaitIndexingEnd (lsp )
107+ await lsp . awaitIndexingEnd ()
109108 assertEqual (await lsp .getObjDirBasename (), "new-value" )
110109
111110 lsp .didChangeConfig ({"scenarioVariables" : None })
112- await awaitIndexingEnd (lsp )
111+ await lsp . awaitIndexingEnd ()
113112 assertEqual (await lsp .getObjDirBasename (), "value-from-init" )
114113
115114
@@ -130,19 +129,19 @@ async def test3(lsp: ALSLanguageClient) -> None:
130129 )
131130 # Because no project file was set, we need a didOpen to load the project
132131 lsp .didOpenVirtual ()
133- await awaitIndexingEnd (lsp )
132+ await lsp . awaitIndexingEnd ()
134133 # No value was provided for the scenario variable, so we should get the default
135134 # value defined in the project.
136135 assertEqual (await lsp .getObjDirBasename (), "value-from-prj" )
137136
138137 # Now let's change the settings and revert back to see if we revert to the right
139138 # value.
140139 lsp .didChangeConfig ({"scenarioVariables" : {"Var" : "new-value" }})
141- await awaitIndexingEnd (lsp )
140+ await lsp . awaitIndexingEnd ()
142141 assertEqual (await lsp .getObjDirBasename (), "new-value" )
143142
144143 lsp .didChangeConfig ({"scenarioVariables" : None })
145- await awaitIndexingEnd (lsp )
144+ await lsp . awaitIndexingEnd ()
146145 assertEqual (await lsp .getObjDirBasename (), "value-from-prj" )
147146
148147
@@ -158,7 +157,7 @@ async def test4(lsp: ALSLanguageClient) -> None:
158157 )
159158 # Because no project file was set, we need a didOpen to load the project
160159 lsp .didOpenVirtual ()
161- await awaitIndexingEnd (lsp )
160+ await lsp . awaitIndexingEnd ()
162161 # No value was provided for the scenario variable, so we should get the default
163162 # value defined in the project.
164163 assertEqual (await lsp .getObjDirBasename (), "value-from-prj" )
@@ -168,14 +167,14 @@ async def test4(lsp: ALSLanguageClient) -> None:
168167 lsp .didChangeConfig (
169168 {"scenarioVariables" : {"Var" : "value-from-first-config-change" }}
170169 )
171- await awaitIndexingEnd (lsp )
170+ await lsp . awaitIndexingEnd ()
172171 assertEqual (await lsp .getObjDirBasename (), "value-from-first-config-change" )
173172
174173 # Now we change to another value, and revert with a null value.
175174 lsp .didChangeConfig ({"scenarioVariables" : {"Var" : "new-value" }})
176- await awaitIndexingEnd (lsp )
175+ await lsp . awaitIndexingEnd ()
177176 assertEqual (await lsp .getObjDirBasename (), "new-value" )
178177
179178 lsp .didChangeConfig ({"scenarioVariables" : None })
180- await awaitIndexingEnd (lsp )
179+ await lsp . awaitIndexingEnd ()
181180 assertEqual (await lsp .getObjDirBasename (), "value-from-first-config-change" )
0 commit comments