Skip to content

Commit afaff20

Browse files
committed
Remove ghc specific diag title
1 parent fdbb2b2 commit afaff20

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

test/functional/FunctionalCodeAction.hs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,15 +48,11 @@ hlintTests = testGroup "hlint suggestions" [
4848
doc <- openDoc "ApplyRefact2.hs" "haskell"
4949
diags@(reduceDiag:_) <- waitForDiagnosticsSource "hlint"
5050

51-
let etaReduceCode = case ghcVersion of
52-
GHC810 -> "refact:Eta reduce"
53-
_ -> "Eta reduce"
54-
5551
liftIO $ do
5652
length diags @?= 2 -- "Eta Reduce" and "Redundant Id"
5753
reduceDiag ^. L.range @?= Range (Position 1 0) (Position 1 12)
5854
reduceDiag ^. L.severity @?= Just DsInfo
59-
reduceDiag ^. L.code @?= Just (StringValue etaReduceCode)
55+
reduceDiag ^. L.code @?= Just (StringValue "refact:Eta reduce")
6056
reduceDiag ^. L.source @?= Just "hlint"
6157

6258
cas <- map fromAction <$> getAllCodeActions doc
@@ -100,7 +96,7 @@ hlintTests = testGroup "hlint suggestions" [
10096

10197
diags' <- waitForDiagnostics
10298

103-
liftIO $ (not $ Just "hlint" `elem` map (^. L.source) diags') @? "There are no hlint diagnostics"
99+
liftIO $ Just "hlint" `notElem` map (^. L.source) diags' @? "There are no hlint diagnostics"
104100

105101
]
106102

0 commit comments

Comments
 (0)