Skip to content

Commit 0f0aaa5

Browse files
Copilotrenemadsen
andcommitted
Fix CS0305 generic type argument errors: add both TResult and TEntity type parameters to AssertUpdate
Co-authored-by: renemadsen <76994+renemadsen@users.noreply.github.com>
1 parent 0927c80 commit 0f0aaa5

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

test/EFCore.MySql.FunctionalTests/BulkUpdates/NorthwindBulkUpdatesMySqlTest.cs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1103,10 +1103,11 @@ public virtual async Task Update_with_invalid_lambda_throws(bool async)
11031103
{
11041104
await AssertTranslationFailed(
11051105
"ss => ss.Set<Customer>().Where(c => c.CustomerID.StartsWith(\"F\"))",
1106-
() => AssertUpdate<Customer>(
1106+
() => AssertUpdate<Customer, Customer>(
11071107
async,
11081108
ss => ss.Set<Customer>().Where(c => c.CustomerID.StartsWith("F")),
1109-
e => e.City = "invalidValue",
1109+
e => e,
1110+
s => s.SetProperty(c => c.City, "invalidValue"),
11101111
rowsAffectedCount: 0));
11111112

11121113
AssertExecuteUpdateSql();
@@ -1242,10 +1243,11 @@ INNER JOIN (
12421243
[MemberData(nameof(IsAsyncData))]
12431244
public virtual async Task Update_with_left_join_set_constant(bool async)
12441245
{
1245-
await AssertUpdate<Customer>(
1246+
await AssertUpdate<Customer, Customer>(
12461247
async,
12471248
ss => ss.Set<Customer>().Where(c => c.CustomerID.StartsWith("F")),
1248-
e => e.ContactName = "Updated",
1249+
e => e,
1250+
s => s.SetProperty(c => c.ContactName, "Updated"),
12491251
rowsAffectedCount: 0);
12501252

12511253
AssertExecuteUpdateSql(

0 commit comments

Comments
 (0)