@@ -1189,7 +1189,6 @@ main:2: error: Revealed type is 'builtins.str'
1189
1189
-- Tests for cross-module second_pass checking.
1190
1190
1191
1191
[case testSymmetricImportCycle1]
1192
- # flags: --hide-error-context
1193
1192
import a
1194
1193
[file a.py]
1195
1194
import b
@@ -1203,10 +1202,12 @@ def g() -> int:
1203
1202
return a.y
1204
1203
x = 1 + 1
1205
1204
[out]
1205
+ tmp/a.py:1: note: In module imported here,
1206
+ main:1: note: ... from here:
1207
+ tmp/b.py: note: In function "g":
1206
1208
tmp/b.py:3: error: Revealed type is 'builtins.int'
1207
1209
1208
1210
[case testSymmetricImportCycle2]
1209
- # flags: --hide-error-context
1210
1211
import b
1211
1212
[file a.py]
1212
1213
import b
@@ -1220,10 +1221,12 @@ def g() -> int:
1220
1221
return a.y
1221
1222
x = 1 + 1
1222
1223
[out]
1224
+ tmp/b.py:1: note: In module imported here,
1225
+ main:1: note: ... from here:
1226
+ tmp/a.py: note: In function "f":
1223
1227
tmp/a.py:3: error: Revealed type is 'builtins.int'
1224
1228
1225
1229
[case testThreePassesRequired]
1226
- # flags: --hide-error-context
1227
1230
import b
1228
1231
[file a.py]
1229
1232
import b
@@ -1236,10 +1239,12 @@ class C:
1236
1239
import a
1237
1240
b = 1 + 1
1238
1241
[out]
1242
+ tmp/b.py:1: note: In module imported here,
1243
+ main:1: note: ... from here:
1244
+ tmp/a.py: note: In member "f1" of class "C":
1239
1245
tmp/a.py:4: error: Cannot determine type of 'x2'
1240
1246
1241
1247
[case testErrorInPassTwo]
1242
- # flags: --hide-error-context
1243
1248
import b
1244
1249
[file a.py]
1245
1250
import b
@@ -1250,10 +1255,12 @@ def f() -> None:
1250
1255
import a
1251
1256
x = 1 + 1
1252
1257
[out]
1258
+ tmp/b.py:1: note: In module imported here,
1259
+ main:1: note: ... from here:
1260
+ tmp/a.py: note: In function "f":
1253
1261
tmp/a.py:4: error: Unsupported operand types for + ("int" and "str")
1254
1262
1255
1263
[case testDeferredDecorator]
1256
- # flags: --hide-error-context
1257
1264
import a
1258
1265
[file a.py]
1259
1266
import b
@@ -1285,4 +1292,3 @@ pass
1285
1292
[file b]
1286
1293
pass
1287
1294
[out]
1288
-
0 commit comments