File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -52,16 +52,18 @@ hlintTests = testGroup "hlint suggestions" [
52
52
length diags @?= 2 -- "Eta Reduce" and "Redundant Id"
53
53
reduceDiag ^. L. range @?= Range (Position 1 0 ) (Position 1 12 )
54
54
reduceDiag ^. L. severity @?= Just DsInfo
55
- reduceDiag ^. L. code @?= Just (StringValue " Eta reduce" )
55
+ reduceDiag ^. L. code @?= Just (StringValue " refact: Eta reduce" )
56
56
reduceDiag ^. L. source @?= Just " hlint"
57
57
58
58
cas <- map fromAction <$> getAllCodeActions doc
59
59
60
60
let applyAll = find (\ ca -> " Apply all hints" `T.isSuffixOf` (ca ^. L. title)) cas
61
61
let redId = find (\ ca -> " Redundant id" `T.isSuffixOf` (ca ^. L. title)) cas
62
+ let redEta = find (\ ca -> " Eta reduce" `T.isSuffixOf` (ca ^. L. title)) cas
62
63
63
64
liftIO $ isJust applyAll @? " There is 'Apply all hints' code action"
64
65
liftIO $ isJust redId @? " There is 'Redundant id' code action"
66
+ liftIO $ isJust redEta @? " There is 'Eta reduce' code action"
65
67
66
68
executeCodeAction (fromJust redId)
67
69
You can’t perform that action at this time.
0 commit comments