@@ -248,8 +248,8 @@ func assertDiagnostic(
248
248
/// - Parameters:
249
249
/// - originalSource: The original source code, which is expected to contain
250
250
/// macros in various places (e.g., `#stringify(x + y)`).
251
- /// - expandedSource : The source code that we expect to see after performing
252
- /// macro expansion on the original source.
251
+ /// - expectedExpandedSource : The source code that we expect to see after
252
+ /// performing macro expansion on the original source.
253
253
/// - diagnostics: The diagnostics when expanding any macro
254
254
/// - macros: The macros that should be expanded, provided as a dictionary
255
255
/// mapping macro names (e.g., `"stringify"`) to implementation types
@@ -258,7 +258,7 @@ func assertDiagnostic(
258
258
/// - testFileName: The name of the test file name to use.
259
259
public func assertMacroExpansion(
260
260
_ originalSource: String ,
261
- expandedSource: String ,
261
+ expandedSource expectedExpandedSource : String ,
262
262
diagnostics: [ DiagnosticSpec ] = [ ] ,
263
263
macros: [ String : Macro . Type ] ,
264
264
testModuleName: String = " TestModule " ,
@@ -294,10 +294,10 @@ public func assertMacroExpansion(
294
294
let formattedSourceFile = expandedSourceFile. formatted ( using: BasicFormat ( indentationWidth: indentationWidth) )
295
295
assertStringsEqualWithDiff (
296
296
formattedSourceFile. description. trimmingCharacters ( in: . newlines) ,
297
- expandedSource . trimmingCharacters ( in: . newlines) ,
297
+ expectedExpandedSource . trimmingCharacters ( in: . newlines) ,
298
298
additionalInfo: """
299
299
Actual expanded source:
300
- \( expandedSource )
300
+ \( formattedSourceFile )
301
301
""" ,
302
302
file: file,
303
303
line: line
0 commit comments