Skip to content

Commit

Permalink
Multi component test: wait for reference ready
Browse files Browse the repository at this point in the history
  • Loading branch information
pepeiborra committed Feb 19, 2022
1 parent 6c7fd99 commit 1d9b6a1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ghcide/test/exe/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -5513,8 +5513,8 @@ simpleMultiTest2 = testCase "simple-multi-test2" $ runWithExtraFiles "multi" $ \
bPath = dir </> "b/B.hs"
bdoc <- openDoc bPath "haskell"
WaitForIdeRuleResult {} <- waitForAction "TypeCheck" bdoc
adoc@(TextDocumentIdentifier auri) <- openDoc aPath "haskell"
WaitForIdeRuleResult {} <- waitForAction "TypeCheck" adoc
TextDocumentIdentifier auri <- openDoc aPath "haskell"
skipManyTill anyMessage $ isReferenceReady aPath
locs <- getDefinitions bdoc (Position 2 7)
let fooL = mkL auri 2 0 2 3
checkDefs locs (pure [fooL])
Expand All @@ -5528,8 +5528,8 @@ simpleMultiTest3 = testCase "simple-multi-test3" $ runWithExtraFiles "multi" $ \
cPath = dir </> "c/C.hs"
bdoc <- openDoc bPath "haskell"
WaitForIdeRuleResult {} <- waitForAction "TypeCheck" bdoc
adoc@(TextDocumentIdentifier auri) <- openDoc aPath "haskell"
WaitForIdeRuleResult {} <- waitForAction "TypeCheck" adoc
TextDocumentIdentifier auri <- openDoc aPath "haskell"
skipManyTill anyMessage $ isReferenceReady aPath
cdoc <- openDoc cPath "haskell"
WaitForIdeRuleResult {} <- waitForAction "TypeCheck" cdoc
locs <- getDefinitions cdoc (Position 2 7)
Expand Down

0 comments on commit 1d9b6a1

Please sign in to comment.