Skip to content

Commit 339938b

Browse files
committed
Extend test cases to cover return types.
1 parent 89e104f commit 339938b

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

StyleCop.Analyzers/StyleCop.Analyzers.Test.CSharp7/MaintainabilityRules/SA1414CSharp7UnitTests.cs

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -160,22 +160,16 @@ public Task ValidateTuplesFromBaseClassAsync()
160160
namespace Test {
161161
class A : B
162162
{
163-
public override void Run((string, string) x)
164-
{
165-
}
163+
public override (string, string) Run((string, string) x) => throw null;
166164
167-
public override void Run((int, int) y)
168-
{
169-
}
165+
public override (int, int) Run((int, int) y) => throw null;
170166
}
171167
172168
abstract class B
173169
{
174-
public abstract void Run(([|string|], [|string|]) x);
170+
public abstract ([|string|], [|string|]) Run(([|string|], [|string|]) x);
175171
176-
public virtual void Run(([|int|], [|int|]) y)
177-
{
178-
}
172+
public virtual ([|int|], [|int|]) Run(([|int|], [|int|]) y) => throw null;
179173
}
180174
}";
181175
return VerifyCSharpDiagnosticAsync(testCode, DiagnosticResult.EmptyDiagnosticResults, default);

0 commit comments

Comments
 (0)