Skip to content

Commit 22b87b2

Browse files
committed
Update tests for macro expansion node name change
1 parent a868f1d commit 22b87b2

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

Tests/SwiftParserTest/translated/ObjectLiteralsTests.swift

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ final class ObjectLiteralsTests: XCTestCase {
99
let _ = [#Color(colorLiteralRed: red, green: green, blue: blue, alpha: alpha)#1️⃣]
1010
""",
1111
diagnostics: [
12-
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in macro expansion expression"),
12+
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in pound literal expression"),
1313
]
1414
)
1515
}
@@ -20,7 +20,7 @@ final class ObjectLiteralsTests: XCTestCase {
2020
let _ = [#Image(imageLiteral: localResourceNameAsString)#1️⃣]
2121
""",
2222
diagnostics: [
23-
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in macro expansion expression"),
23+
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in pound literal expression"),
2424
]
2525
)
2626
}
@@ -31,7 +31,7 @@ final class ObjectLiteralsTests: XCTestCase {
3131
let _ = [#FileReference(fileReferenceLiteral: localResourceNameAsString)#1️⃣]
3232
""",
3333
diagnostics: [
34-
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in macro expansion expression"),
34+
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in pound literal expression"),
3535
]
3636
)
3737
}
@@ -93,8 +93,8 @@ final class ObjectLiteralsTests: XCTestCase {
9393
let _ = [#1️⃣#2️⃣]
9494
""",
9595
diagnostics: [
96-
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in macro expansion expression"),
97-
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in macro expansion expression"),
96+
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in pound literal expression"),
97+
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in pound literal expression"),
9898
]
9999
)
100100
}
@@ -116,7 +116,7 @@ final class ObjectLiteralsTests: XCTestCase {
116116
let _ = [1️⃣#Color(red: 1, green: 1, blue: 1)#2️⃣3️⃣
117117
""",
118118
diagnostics: [
119-
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in macro expansion expression"),
119+
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in pound literal expression"),
120120
DiagnosticSpec(locationMarker: "3️⃣", message: "expected ']' to end array"),
121121
]
122122
)
@@ -128,7 +128,7 @@ final class ObjectLiteralsTests: XCTestCase {
128128
let _ = [#Color(withRed: 1, green: 1, whatever: 2)#1️⃣]
129129
""",
130130
diagnostics: [
131-
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in macro expansion expression")
131+
DiagnosticSpec(locationMarker: "1️⃣", message: "expected identifier in pound literal expression")
132132
]
133133
)
134134
}

Tests/SwiftParserTest/translated/RawStringErrorsTests.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ final class RawStringErrorsTests: XCTestCase {
4141
// TODO: Old parser expected error on line 1: consecutive statements on a line must be separated by ';'
4242
// TODO: Old parser expected error on line 1: expected expression
4343
DiagnosticSpec(locationMarker: "1️⃣", message: "consecutive statements on a line must be separated by ';'"),
44-
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in macro expansion declaration"),
45-
DiagnosticSpec(locationMarker: "3️⃣", message: "expected identifier in macro expansion declaration"),
46-
DiagnosticSpec(locationMarker: "4️⃣", message: "expected identifier in macro expansion declaration"),
44+
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in pound literal declaration"),
45+
DiagnosticSpec(locationMarker: "3️⃣", message: "expected identifier in pound literal declaration"),
46+
DiagnosticSpec(locationMarker: "4️⃣", message: "expected identifier in pound literal declaration"),
4747
]
4848
)
4949
}
@@ -70,9 +70,9 @@ final class RawStringErrorsTests: XCTestCase {
7070
// TODO: Old parser expected error on line 1: consecutive statements on a line must be separated by ';'
7171
// TODO: Old parser expected error on line 1: expected expression
7272
DiagnosticSpec(locationMarker: "1️⃣", message: "consecutive statements on a line must be separated by ';'"),
73-
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in macro expansion declaration"),
74-
DiagnosticSpec(locationMarker: "3️⃣", message: "expected identifier in macro expansion declaration"),
75-
DiagnosticSpec(locationMarker: "4️⃣", message: "expected identifier in macro expansion declaration"),
73+
DiagnosticSpec(locationMarker: "2️⃣", message: "expected identifier in pound literal declaration"),
74+
DiagnosticSpec(locationMarker: "3️⃣", message: "expected identifier in pound literal declaration"),
75+
DiagnosticSpec(locationMarker: "4️⃣", message: "expected identifier in pound literal declaration"),
7676
]
7777
)
7878
}

0 commit comments

Comments
 (0)