Skip to content

Commit 4fb8e57

Browse files
committed
Add reproducer
1 parent 310b842 commit 4fb8e57

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

plugins/hls-rename-plugin/test/Main.hs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ tests :: TestTree
2323
tests = testGroup "Rename"
2424
[ goldenWithRename "Data constructor" "DataConstructor" $ \doc ->
2525
rename doc (Position 0 15) "Op"
26+
, goldenWithRename "Data constructor with fields" "DataConstructorWithFields" $ \doc ->
27+
rename doc (Position 0 13) "FooRenamed"
2628
, goldenWithRename "Exported function" "ExportedFunction" $ \doc ->
2729
rename doc (Position 2 1) "quux"
2830
, ignoreForGhcVersions [GHC90, GHC92] recordConstructorIssue $
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
data Foo = FooRenamed { a :: Int, b :: Bool }
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
data Foo = Foo { a :: Int, b :: Bool }

0 commit comments

Comments
 (0)