Skip to content

Commit 081ea8f

Browse files
committed
Add another signature help tests: RankNTypes(forall in middle)
1 parent c3224d7 commit 081ea8f

File tree

1 file changed

+11
-0
lines changed
  • plugins/hls-signature-help-plugin/test

1 file changed

+11
-0
lines changed

plugins/hls-signature-help-plugin/test/Main.hs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,17 @@ main =
250250
Just $ SignatureHelp [SignatureInformation "f :: forall a. Maybe a -> forall b. (a, b) -> b" Nothing (Just [ParameterInformation (InR (15,22)) Nothing, ParameterInformation (InR (36,42)) Nothing]) (Just (InL 0)), SignatureInformation "f :: Maybe Bool -> forall b. (Bool, b) -> b" Nothing (Just [ParameterInformation (InR (5,15)) Nothing, ParameterInformation (InR (29,38)) Nothing]) (Just (InL 0))] (Just 0) (Just (InL 0)),
251251
Just $ SignatureHelp [SignatureInformation "f :: forall a. Maybe a -> forall b. (a, b) -> b" Nothing (Just [ParameterInformation (InR (15,22)) Nothing, ParameterInformation (InR (36,42)) Nothing]) (Just (InL 0)), SignatureInformation "f :: Maybe Integer -> forall b. (Integer, b) -> b" Nothing (Just [ParameterInformation (InR (5,18)) Nothing, ParameterInformation (InR (32,44)) Nothing]) (Just (InL 0))] (Just 0) (Just (InL 0))
252252
],
253+
mkTest
254+
"RankNTypes(forall in middle), another"
255+
[trimming|
256+
f :: l -> forall a. a -> a
257+
f = _
258+
x = f 1
259+
^ ^
260+
|]
261+
[ Nothing,
262+
Just $ SignatureHelp [SignatureInformation "f :: forall l. l -> forall a. a -> a" Nothing (Just [ParameterInformation (InR (15,16)) Nothing, ParameterInformation (InR (30,31)) Nothing]) (Just (InL 0)), SignatureInformation "f :: Integer -> forall a. a -> a" Nothing (Just [ParameterInformation (InR (5,12)) Nothing, ParameterInformation (InR (26,27)) Nothing]) (Just (InL 0))] (Just 0) (Just (InL 0))
263+
],
253264
mkTest
254265
"RankNTypes(forall in middle), again"
255266
[trimming|

0 commit comments

Comments
 (0)