@@ -140,13 +140,19 @@ defineTest({
140
140
} ,
141
141
} )
142
142
143
+ expect ( client . serverCapabilities ) . not . toEqual ( [ ] )
144
+ let ids1 = client . serverCapabilities . map ( ( cap ) => cap . id )
145
+
143
146
// Remove the CSS file
144
147
let didRestart = new Promise ( ( resolve ) => {
145
148
client . conn . onNotification ( '@/tailwindCSS/serverRestarted' , resolve )
146
149
} )
147
150
await fs . unlink ( path . resolve ( root , 'app.css' ) )
148
151
await didRestart
149
152
153
+ expect ( client . serverCapabilities ) . not . toEqual ( [ ] )
154
+ let ids2 = client . serverCapabilities . map ( ( cap ) => cap . id )
155
+
150
156
// <div class="text-primary">
151
157
// ^
152
158
let hover2 = await doc . hover ( { line : 0 , character : 13 } )
@@ -164,11 +170,23 @@ defineTest({
164
170
)
165
171
await didRestartAgain
166
172
173
+ expect ( client . serverCapabilities ) . not . toEqual ( [ ] )
174
+ let ids3 = client . serverCapabilities . map ( ( cap ) => cap . id )
175
+
167
176
await new Promise ( ( resolve ) => setTimeout ( resolve , 500 ) )
168
177
169
178
// <div class="text-primary">
170
179
// ^
171
180
let hover3 = await doc . hover ( { line : 0 , character : 13 } )
172
181
expect ( hover3 ) . toEqual ( null )
182
+
183
+ expect ( ids1 ) . not . toContainEqual ( expect . toBeOneOf ( ids2 ) )
184
+ expect ( ids1 ) . not . toContainEqual ( expect . toBeOneOf ( ids3 ) )
185
+
186
+ expect ( ids2 ) . not . toContainEqual ( expect . toBeOneOf ( ids1 ) )
187
+ expect ( ids2 ) . not . toContainEqual ( expect . toBeOneOf ( ids3 ) )
188
+
189
+ expect ( ids3 ) . not . toContainEqual ( expect . toBeOneOf ( ids1 ) )
190
+ expect ( ids3 ) . not . toContainEqual ( expect . toBeOneOf ( ids2 ) )
173
191
} ,
174
192
} )
0 commit comments