Skip to content

Commit 237c7a9

Browse files
committed
Update tests
1 parent ac0ce76 commit 237c7a9

2 files changed

Lines changed: 36 additions & 36 deletions

File tree

src/EditorFeatures/CSharpTest/GenerateFromMembers/AddConstructorParametersFromMembers/AddConstructorParametersFromMembersTests.cs

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public Program(int i, string s)
8989
}
9090
}
9191
""",
92-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
92+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
9393
}.RunAsync();
9494
}
9595

@@ -131,7 +131,7 @@ public Program(
131131
}
132132
}
133133
""",
134-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
134+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
135135
}.RunAsync();
136136
}
137137

@@ -180,7 +180,7 @@ public Program(
180180
}
181181
}
182182
""",
183-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int, string)"), codeAction.Title)
183+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i, string s)"), codeAction.Title)
184184
}.RunAsync();
185185
}
186186

@@ -227,7 +227,7 @@ public Program(int i,
227227
}
228228
}
229229
""",
230-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int, string)"), codeAction.Title)
230+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i, string s)"), codeAction.Title)
231231
}.RunAsync();
232232
}
233233

@@ -274,7 +274,7 @@ public Program(int i,
274274
}
275275
}
276276
""",
277-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int, string)"), codeAction.Title)
277+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i, string s)"), codeAction.Title)
278278
}.RunAsync();
279279
}
280280

@@ -316,7 +316,7 @@ public Program(int i, string s = null)
316316
}
317317
""",
318318
CodeActionIndex = 1,
319-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_optional_parameters_to_0, "Program(int)"), codeAction.Title)
319+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_optional_parameters_to_0, "Program(int i)"), codeAction.Title)
320320
}.RunAsync();
321321
}
322322

@@ -371,7 +371,7 @@ public Program(int i, string s, bool b) : this(i)
371371
}
372372
""",
373373
CodeActionIndex = 1,
374-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "Program(int, string)"), codeAction.Title)
374+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "Program(int i, string s)"), codeAction.Title)
375375
}.RunAsync();
376376
}
377377

@@ -426,7 +426,7 @@ public Program(int i, string s, bool b = false) : this(i)
426426
}
427427
""",
428428
CodeActionIndex = 3,
429-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "Program(int, string)"), codeAction.Title)
429+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "Program(int i, string s)"), codeAction.Title)
430430
}.RunAsync();
431431
}
432432

@@ -466,7 +466,7 @@ public Program(bool b, HashSet<string> s)
466466
}
467467
}
468468
""",
469-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(bool)"), codeAction.Title)
469+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(bool b)"), codeAction.Title)
470470
}.RunAsync();
471471
}
472472

@@ -507,7 +507,7 @@ public Program(bool b, HashSet<string> s = null)
507507
}
508508
""",
509509
CodeActionIndex = 1,
510-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_optional_parameters_to_0, "Program(bool)"), codeAction.Title)
510+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_optional_parameters_to_0, "Program(bool b)"), codeAction.Title)
511511
}.RunAsync();
512512
}
513513

@@ -1195,7 +1195,7 @@ public C(int i, int j, int k)
11951195
}
11961196
}
11971197
""",
1198-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int)"), codeAction.Title)
1198+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i)"), codeAction.Title)
11991199
}.RunAsync();
12001200
}
12011201

@@ -1240,7 +1240,7 @@ public C(int i, int j, int l)
12401240
TestCode = source,
12411241
FixedCode = expected,
12421242
CodeActionIndex = 1,
1243-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, int)"), codeAction.Title)
1243+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, int j)"), codeAction.Title)
12441244
}.RunAsync();
12451245
}
12461246

@@ -1286,7 +1286,7 @@ public C(int i, int j, int k, int l)
12861286
TestCode = source,
12871287
FixedCode = expected,
12881288
CodeActionIndex = 2,
1289-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, int, int)"), codeAction.Title)
1289+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, int j, int k)"), codeAction.Title)
12901290
}.RunAsync();
12911291
}
12921292

@@ -1331,7 +1331,7 @@ public C(int i, int j, int k)
13311331
TestCode = source,
13321332
FixedCode = expected,
13331333
CodeActionIndex = 3,
1334-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int)"), codeAction.Title)
1334+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i)"), codeAction.Title)
13351335
}.RunAsync();
13361336
}
13371337

@@ -1377,7 +1377,7 @@ public C(int i, int j, int l = 0)
13771377
TestCode = source,
13781378
FixedCode = expected,
13791379
CodeActionIndex = 4,
1380-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, int)"), codeAction.Title)
1380+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, int j)"), codeAction.Title)
13811381
}.RunAsync();
13821382
}
13831383

@@ -1422,7 +1422,7 @@ public C(int i, int j, int k, int l = 0)
14221422
TestCode = source,
14231423
FixedCode = expected,
14241424
CodeActionIndex = 5,
1425-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, int, int)"), codeAction.Title)
1425+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, int j, int k)"), codeAction.Title)
14261426
}.RunAsync();
14271427
}
14281428

@@ -1483,7 +1483,7 @@ public C(int i, double j, int k, int l)
14831483
TestCode = source,
14841484
FixedCode = expected,
14851485
CodeActionIndex = 1,
1486-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, double, int)"), codeAction.Title)
1486+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, double j, int k)"), codeAction.Title)
14871487
}.RunAsync();
14881488
}
14891489

@@ -1540,7 +1540,7 @@ public C(int i, double j = 0, int l = 0)
15401540
TestCode = source,
15411541
FixedCode = expected,
15421542
CodeActionIndex = 3,
1543-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, double)"), codeAction.Title)
1543+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i, double j)"), codeAction.Title)
15441544
}.RunAsync();
15451545
}
15461546

@@ -1582,7 +1582,7 @@ public C(int l, double m, int n = 0)
15821582
}
15831583
}
15841584
""",
1585-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int)"), codeAction.Title)
1585+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int i)"), codeAction.Title)
15861586
}.RunAsync();
15871587
}
15881588

@@ -1627,7 +1627,7 @@ public C(int l, double m, int n = 0, int p = 0)
16271627
TestCode = source,
16281628
FixedCode = expected,
16291629
CodeActionIndex = 2,
1630-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int, double, int)"), codeAction.Title)
1630+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(CodeFixesResources.Add_to_0, "C(int l, double m, int n)"), codeAction.Title)
16311631
}.RunAsync();
16321632
}
16331633

@@ -1945,7 +1945,7 @@ public Program(int i, string s)
19451945
}
19461946
}
19471947
""",
1948-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
1948+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
19491949
}.RunAsync();
19501950
}
19511951

@@ -1985,7 +1985,7 @@ public Program(int i, string s)
19851985
}
19861986
}
19871987
""",
1988-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
1988+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
19891989
}.RunAsync();
19901990
}
19911991

@@ -2025,7 +2025,7 @@ public Program(int i, string s)
20252025
}
20262026
}
20272027
""",
2028-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2028+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
20292029
}.RunAsync();
20302030
}
20312031

@@ -2065,7 +2065,7 @@ public Program(int i, string s)
20652065
}
20662066
}
20672067
""",
2068-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2068+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
20692069
}.RunAsync();
20702070
}
20712071

@@ -2105,7 +2105,7 @@ public Program(int i, string s)
21052105
}
21062106
}
21072107
""",
2108-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2108+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
21092109
}.RunAsync();
21102110
}
21112111

@@ -2145,7 +2145,7 @@ public Program(int i, string s)
21452145
}
21462146
}
21472147
""",
2148-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2148+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
21492149
}.RunAsync();
21502150
}
21512151

@@ -2186,7 +2186,7 @@ public Program(int i, string s, string t)
21862186
}
21872187
}
21882188
""",
2189-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2189+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
21902190
}.RunAsync();
21912191
}
21922192

@@ -2227,7 +2227,7 @@ public Program(int i, string s, string t)
22272227
}
22282228
}
22292229
""",
2230-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2230+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
22312231
}.RunAsync();
22322232
}
22332233

@@ -2267,7 +2267,7 @@ public Program(int i, string s)
22672267
}
22682268
}
22692269
""",
2270-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2270+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
22712271
}.RunAsync();
22722272
}
22732273

@@ -2307,7 +2307,7 @@ public Program(int i, string s)
23072307
}
23082308
}
23092309
""",
2310-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2310+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
23112311
}.RunAsync();
23122312
}
23132313

@@ -2347,7 +2347,7 @@ public Program(int i, string t)
23472347
}
23482348
}
23492349
""",
2350-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2350+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
23512351
}.RunAsync();
23522352
}
23532353

@@ -2387,7 +2387,7 @@ public Program(int i, string t)
23872387
}
23882388
}
23892389
""",
2390-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int)"), codeAction.Title)
2390+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "Program(int i)"), codeAction.Title)
23912391
}.RunAsync();
23922392
}
23932393

@@ -2690,7 +2690,7 @@ public C(
26902690
}
26912691
}
26922692
""",
2693-
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "C(int, int)"), codeAction.Title)
2693+
CodeActionVerifier = (codeAction, verifier) => verifier.Equal(string.Format(FeaturesResources.Add_parameters_to_0, "C(int original, int original2)"), codeAction.Title)
26942694
}.RunAsync();
26952695
}
26962696

src/EditorFeatures/CSharpTest/GenerateFromMembers/GenerateConstructorFromMembers/GenerateConstructorFromMembersTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -741,7 +741,7 @@ class Program
741741
HashSet<string> s;|]
742742
}
743743
""",
744-
string.Format(FeaturesResources.Generate_constructor_0_1, "Program", "bool, HashSet<string>"));
744+
string.Format(FeaturesResources.Generate_constructor_0_1, "Program", "bool b, HashSet<string> s"));
745745
}
746746

747747
[Fact]
@@ -762,7 +762,7 @@ public Program(bool b)
762762
}
763763
}
764764
""",
765-
string.Format(FeaturesResources.Generate_field_assigning_constructor_0_1, "Program", "bool, HashSet<string>"));
765+
string.Format(FeaturesResources.Generate_field_assigning_constructor_0_1, "Program", "bool b, HashSet<string> s"));
766766
}
767767

768768
[Fact]
@@ -783,7 +783,7 @@ public Program(bool b)
783783
}
784784
}
785785
""",
786-
string.Format(FeaturesResources.Generate_delegating_constructor_0_1, "Program", "bool, HashSet<string>"),
786+
string.Format(FeaturesResources.Generate_delegating_constructor_0_1, "Program", "bool b, HashSet<string> s"),
787787
index: 1);
788788
}
789789

0 commit comments

Comments
 (0)