Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions src/Dapr.Actors.Generators/ActorClientGenerator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,65 @@
var actorClientClassTypeParameters = descriptor.InterfaceType.TypeParameters
.Select(x => SyntaxFactory.TypeParameter(x.ToString()));

// Create constraint clauses for type parameters
var constraintClauses = new List<TypeParameterConstraintClauseSyntax>();

// For each type parameter, create constraint clauses based on the interface's constraints
foreach (var typeParam in descriptor.InterfaceType.TypeParameters)
{
if (typeParam.HasReferenceTypeConstraint ||
typeParam.HasValueTypeConstraint ||
typeParam.HasUnmanagedTypeConstraint ||
typeParam.HasNotNullConstraint ||
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The condition deciding whether to emit a where ... clause doesn’t include HasConstructorConstraint. If a type parameter only has new() (no other constraints), no constraint clause will be generated, even though the PR claims new() is supported.

Suggested change
typeParam.HasNotNullConstraint ||
typeParam.HasNotNullConstraint ||
typeParam.HasConstructorConstraint ||

Copilot uses AI. Check for mistakes.
typeParam.ConstraintTypes.Length > 0)
{
var constraints = new List<TypeParameterConstraintSyntax>();

// Add class/struct constraints
if (typeParam.HasReferenceTypeConstraint)
{
constraints.Add(SyntaxFactory.ClassOrStructConstraint(SyntaxKind.ClassConstraint));
}
else if (typeParam.HasValueTypeConstraint)
{
constraints.Add(SyntaxFactory.ClassOrStructConstraint(SyntaxKind.StructConstraint));

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

'else' cannot start a statement.

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

; expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

) expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

Invalid expression term 'else'

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

Syntax error, '(' expected

Check failure on line 188 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

'else' cannot start a statement.
else if (typeParam.HasValueTypeConstraint && !typeParam.HasUnmanagedTypeConstraint)
{
constraints.Add(SyntaxFactory.ClassOrStructConstraint(SyntaxKind.StructConstraint));
}
Comment thread
oising marked this conversation as resolved.

// Add unmanaged constraint
if (typeParam.HasUnmanagedTypeConstraint)
{
constraints.Add(SyntaxFactory.TypeConstraint(SyntaxFactory.IdentifierName("unmanaged")));
Copy link

Copilot AI Aug 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The unmanaged constraint should be added before type constraints but after class/struct constraints. The current order may not follow C# constraint ordering requirements where 'unmanaged' should come before interface constraints.

Copilot uses AI. Check for mistakes.
Copy link
Copy Markdown
Author

@oising oising Aug 7, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

}

// Add type constraints (e.g., where T : IInterface)
foreach (var constraintType in typeParam.ConstraintTypes)
{
constraints.Add(SyntaxFactory.TypeConstraint(
SyntaxFactory.ParseTypeName(constraintType.ToString())));
}

// Add notnull constraint
if (typeParam.HasNotNullConstraint)
{
constraints.Add(SyntaxFactory.TypeConstraint(SyntaxFactory.IdentifierName("notnull")));
}
Comment on lines +200 to +211
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Constraint ordering here can produce invalid C#: notnull is appended after the type/interface constraints, but C# requires special constraints (class/struct/unmanaged/notnull) to come before any type constraints, with new() last. Reorder the list so notnull is emitted before ConstraintTypes (and keep new() last).

Copilot uses AI. Check for mistakes.

// Add new() constraint - must be last
if (typeParam.HasConstructorConstraint)
{
constraints.Add(SyntaxFactory.ConstructorConstraint());
}

constraintClauses.Add(
SyntaxFactory.TypeParameterConstraintClause(
SyntaxFactory.IdentifierName(typeParam.Name),
SyntaxFactory.SeparatedList(constraints)));
}
}

var actorClientClassDeclaration = (actorClientClassTypeParameters.Count() == 0)
? SyntaxFactory.ClassDeclaration(descriptor.ClientTypeName)
.WithModifiers(SyntaxFactory.TokenList(actorClientClassModifiers))
Expand All @@ -174,6 +233,7 @@
: SyntaxFactory.ClassDeclaration(descriptor.ClientTypeName)
.WithModifiers(SyntaxFactory.TokenList(actorClientClassModifiers))
.WithTypeParameterList(SyntaxFactory.TypeParameterList(SyntaxFactory.SeparatedList(actorClientClassTypeParameters)))
.WithConstraintClauses(SyntaxFactory.List(constraintClauses)) // Add constraint clauses to the class
.WithMembers(SyntaxFactory.List(actorMembers))
.WithBaseList(SyntaxFactory.BaseList(
SyntaxFactory.Token(SyntaxKind.ColonToken),
Expand All @@ -192,7 +252,7 @@
.ToFullString();

context.AddSource($"{descriptor.FullyQualifiedTypeName}.g.cs", compilationOutput);
}

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 8.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 9.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Unit Tests .NET 10.0 / - test/Dapr.Actors.Generators.Test/Dapr.Actors.Generators.Test.csproj

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / Build

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / coverage

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (9.0)

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (8.0)

} expected

Check failure on line 255 in src/Dapr.Actors.Generators/ActorClientGenerator.cs

View workflow job for this annotation

GitHub Actions / integration-test / Integration Tests (10.0)

} expected
catch (DiagnosticsException e)
{
foreach (var diagnostic in e.Diagnostics)
Expand Down
116 changes: 116 additions & 0 deletions test/Dapr.Actors.Generators.Test/ActorClientGeneratorTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -877,4 +877,120 @@ public interface ITestActor

await test.RunAsync();
}

[Fact]
public async Task TestGenericWithConstraints()
{
var originalSource = @"
using Dapr.Actors.Generators;
using System.Threading.Tasks;

namespace Test
{
public interface ITrait
{
string GetName();
}

[GenerateActorClient]
public interface ITestActor<in TTrait> where TTrait : ITrait
{
Task<bool> SetTrait(TTrait trait);
Task<ITrait> GetTrait(string name);
}
Comment on lines +896 to +900
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new test input source won’t compile: the type parameter is TTrait (ITestActor<in TTrait>), but SetTrait uses TTrait as the parameter type. This should reference the declared type parameter name consistently so the generator test is exercising constraint copying rather than failing to compile the input.

Copilot uses AI. Check for mistakes.
}";

var generatedSource = @"// <auto-generated/>
#nullable enable
namespace Test
{
public sealed class TestActorClient<TTrait> : Test.ITestActor<TTrait> where TTrait : Test.ITrait
{
Comment on lines +907 to +908
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The expected generated code has inconsistent type parameter names: the class is declared as TestActorClient<TTrait> but the constraint clause refers to TTrait. These must match (and should likely use the same type parameter identifier as the source interface).

Copilot uses AI. Check for mistakes.
private readonly Dapr.Actors.Client.ActorProxy actorProxy;
public TestActorClient(Dapr.Actors.Client.ActorProxy actorProxy)
{
if (actorProxy is null)
{
throw new System.ArgumentNullException(nameof(actorProxy));
}

this.actorProxy = actorProxy;
}

public System.Threading.Tasks.Task<Test.ITrait> GetTrait(string name)
{
return this.actorProxy.InvokeMethodAsync<string, Test.ITrait>(""GetTrait"", name);
}

public System.Threading.Tasks.Task<bool> SetTrait(TTrait trait)
{
return this.actorProxy.InvokeMethodAsync<TTrait, bool>(""SetTrait"", trait);
}
}
}";

await CreateTest(originalSource, "Test.TestActorClient.g.cs", generatedSource).RunAsync();
}

[Fact]
public async Task TestGenericWithMultipleTypeParametersAndConstraints()
{
var originalSource = @"
using Dapr.Actors.Generators;
using System.Threading.Tasks;

namespace Test
{
public interface ITrait
{
string GetName();
}

public interface IValidator<T>
{
bool Validate(T item);
}

[GenerateActorClient]
public interface ITestActor<TTrait, TValidator>
where TTrait : ITrait, new()
where TValidator : class, IValidator<TTrait>
{
Comment on lines +954 to +958
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test input source has a typo in the constraint clause: the interface type parameter is TTrait, but the where clause uses TTrait. As written, the originalSource won’t compile, so the test won’t validate constraint copying.

Copilot uses AI. Check for mistakes.
Task<bool> SetTrait(TTrait trait);
Task<TTrait> GetValidatedTrait(string name);
}
}";

var generatedSource = @"// <auto-generated/>
#nullable enable
namespace Test
{
public sealed class TestActorClient<TTrait, TValidator> : Test.ITestActor<TTrait, TValidator> where TTrait : Test.ITrait, new()
where TValidator : class, Test.IValidator<TTrait>
{
private readonly Dapr.Actors.Client.ActorProxy actorProxy;
public TestActorClient(Dapr.Actors.Client.ActorProxy actorProxy)
{
if (actorProxy is null)
{
throw new System.ArgumentNullException(nameof(actorProxy));
}

this.actorProxy = actorProxy;
}

public System.Threading.Tasks.Task<TTrait> GetValidatedTrait(string name)
{
return this.actorProxy.InvokeMethodAsync<string, TTrait>(""GetValidatedTrait"", name);
}
Comment on lines +982 to +985
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The expected generated code uses InvokeMethodAsync<string, TTrait>(...), but TTrait isn’t a type parameter on the generated class (it’s TTrait). This mismatch will make the expected output invalid and fail the snapshot comparison once the generator is fixed.

Copilot uses AI. Check for mistakes.

public System.Threading.Tasks.Task<bool> SetTrait(TTrait trait)
{
return this.actorProxy.InvokeMethodAsync<TTrait, bool>(""SetTrait"", trait);
}
}
}";

await CreateTest(originalSource, "Test.TestActorClient.g.cs", generatedSource).RunAsync();
}
}
Loading