Skip to content

Commit 1f5c60d

Browse files
authored
ignore simple-multi-def-test for windows since #4270 (#4345)
1 parent 495af1f commit 1f5c60d

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

ghcide/test/exe/CradleTests.hs

+9-1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ import Language.LSP.Protocol.Types hiding
2929
import Language.LSP.Test
3030
import System.FilePath
3131
import System.IO.Extra hiding (withTempDir)
32+
import Test.Hls.Util (EnvSpec (..), OS (..),
33+
ignoreInEnv)
3234
import Test.Tasty
3335
import Test.Tasty.HUnit
3436

@@ -169,7 +171,8 @@ simpleMultiTest3 variant =
169171

170172
-- Like simpleMultiTest but open the files in component 'a' in a separate session
171173
simpleMultiDefTest :: FilePath -> TestTree
172-
simpleMultiDefTest variant = testCase (multiTestName variant "def-test") $ runWithExtraFiles variant $ \dir -> do
174+
simpleMultiDefTest variant = ignoreForWindows $ testCase testName $
175+
runWithExtraFiles variant $ \dir -> do
173176
let aPath = dir </> "a/A.hs"
174177
bPath = dir </> "b/B.hs"
175178
adoc <- liftIO $ runInDir dir $ do
@@ -184,6 +187,11 @@ simpleMultiDefTest variant = testCase (multiTestName variant "def-test") $ runWi
184187
let fooL = mkL (adoc ^. L.uri) 2 0 2 3
185188
checkDefs locs (pure [fooL])
186189
expectNoMoreDiagnostics 0.5
190+
where
191+
testName = multiTestName variant "def-test"
192+
ignoreForWindows
193+
| testName == "simple-multi-def-test" = ignoreInEnv [HostOS Windows] "Test is flaky on Windows, see #4270"
194+
| otherwise = id
187195

188196
multiRexportTest :: TestTree
189197
multiRexportTest =

0 commit comments

Comments
 (0)