@@ -51,8 +51,8 @@ ifaceTHTest = testWithExtraFiles "iface-th-test" "TH" $ \dir -> do
51
51
-- Check that the change propagates to C
52
52
changeDoc cdoc [TextDocumentContentChangeEvent . InR $ TextDocumentContentChangeWholeDocument cSource]
53
53
expectDiagnostics
54
- [(" THC.hs" , [(DiagnosticSeverity_Error , (4 , 4 ), " Couldn't match expected type '()' with actual type 'Bool'" , Nothing )])
55
- ,(" THB.hs" , [(DiagnosticSeverity_Warning , (4 ,1 ), " Top-level binding" , Nothing )])]
54
+ [(" THC.hs" , [(DiagnosticSeverity_Error , (4 , 4 ), " Couldn't match expected type '()' with actual type 'Bool'" , Just " GHC-83865 " )])
55
+ ,(" THB.hs" , [(DiagnosticSeverity_Warning , (4 ,1 ), " Top-level binding" , Just " GHC-38417 " )])]
56
56
closeDoc cdoc
57
57
58
58
ifaceErrorTest :: TestTree
@@ -66,7 +66,7 @@ ifaceErrorTest = testWithExtraFiles "iface-error-test-1" "recomp" $ \dir -> do
66
66
67
67
bdoc <- createDoc bPath " haskell" bSource
68
68
expectDiagnostics
69
- [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Nothing )])] -- So what we know P has been loaded
69
+ [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Just " GHC-38417 " )])] -- So what we know P has been loaded
70
70
71
71
-- Change y from Int to B
72
72
changeDoc bdoc [ TextDocumentContentChangeEvent . InR . TextDocumentContentChangeWholeDocument $
@@ -78,7 +78,7 @@ ifaceErrorTest = testWithExtraFiles "iface-error-test-1" "recomp" $ \dir -> do
78
78
79
79
-- Check that the error propagates to A
80
80
expectDiagnostics
81
- [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Nothing )])]
81
+ [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Just " GHC-83865 " )])]
82
82
83
83
-- Check that we wrote the interfaces for B when we saved
84
84
hidir <- getInterfaceFilesDir bdoc
@@ -87,7 +87,7 @@ ifaceErrorTest = testWithExtraFiles "iface-error-test-1" "recomp" $ \dir -> do
87
87
88
88
pdoc <- openDoc pPath " haskell"
89
89
expectDiagnostics
90
- [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Nothing )])
90
+ [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Just " GHC-38417 " )])
91
91
]
92
92
changeDoc pdoc [TextDocumentContentChangeEvent . InR . TextDocumentContentChangeWholeDocument $ pSource <> " \n foo = y :: Bool" ]
93
93
-- Now in P we have
@@ -99,8 +99,8 @@ ifaceErrorTest = testWithExtraFiles "iface-error-test-1" "recomp" $ \dir -> do
99
99
-- - The diagnostic for A has already been received. Ghcide does not repeat diagnostics
100
100
-- - P is being typechecked with the last successful artifacts for A.
101
101
expectDiagnostics
102
- [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Nothing )])
103
- ,(" P.hs" , [(DiagnosticSeverity_Warning ,(6 ,0 ), " Top-level binding" , Nothing )])
102
+ [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Just " GHC-38417 " )])
103
+ ,(" P.hs" , [(DiagnosticSeverity_Warning ,(6 ,0 ), " Top-level binding" , Just " GHC-38417 " )])
104
104
]
105
105
expectNoMoreDiagnostics 2
106
106
@@ -115,7 +115,7 @@ ifaceErrorTest2 = testWithExtraFiles "iface-error-test-2" "recomp" $ \dir -> do
115
115
bdoc <- createDoc bPath " haskell" bSource
116
116
pdoc <- createDoc pPath " haskell" pSource
117
117
expectDiagnostics
118
- [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Nothing )])] -- So that we know P has been loaded
118
+ [(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Just " GHC-38417 " )])] -- So that we know P has been loaded
119
119
120
120
-- Change y from Int to B
121
121
changeDoc bdoc [TextDocumentContentChangeEvent . InR . TextDocumentContentChangeWholeDocument $
@@ -131,9 +131,9 @@ ifaceErrorTest2 = testWithExtraFiles "iface-error-test-2" "recomp" $ \dir -> do
131
131
expectDiagnostics
132
132
-- As in the other test, P is being typechecked with the last successful artifacts for A
133
133
-- (ot thanks to -fdeferred-type-errors)
134
- [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Nothing )])
135
- ,(" P.hs" , [(DiagnosticSeverity_Warning , (4 , 0 ), " Top-level binding" , Nothing )])
136
- ,(" P.hs" , [(DiagnosticSeverity_Warning , (6 , 0 ), " Top-level binding" , Nothing )])
134
+ [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Just " GHC-83865 " )])
135
+ ,(" P.hs" , [(DiagnosticSeverity_Warning , (4 , 0 ), " Top-level binding" , Just " GHC-38417 " )])
136
+ ,(" P.hs" , [(DiagnosticSeverity_Warning , (6 , 0 ), " Top-level binding" , Just " GHC-38417 " )])
137
137
]
138
138
139
139
expectNoMoreDiagnostics 2
@@ -157,7 +157,7 @@ ifaceErrorTest3 = testWithExtraFiles "iface-error-test-3" "recomp" $ \dir -> do
157
157
-- In this example the interface file for A should not exist (modulo the cache folder)
158
158
-- Despite that P still type checks, as we can generate an interface file for A thanks to -fdeferred-type-errors
159
159
expectDiagnostics
160
- [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Nothing )])
161
- ,(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Nothing )])
160
+ [(" A.hs" , [(DiagnosticSeverity_Error , (5 , 4 ), " Couldn't match expected type 'Int' with actual type 'Bool'" , Just " GHC-83865 " )])
161
+ ,(" P.hs" , [(DiagnosticSeverity_Warning ,(4 ,0 ), " Top-level binding" , Just " GHC-38417 " )])
162
162
]
163
163
expectNoMoreDiagnostics 2
0 commit comments