Skip to content

Commit 0f7ee2f

Browse files
Copilotrenemadsen
andcommitted
Addressing PR comments
Co-authored-by: renemadsen <76994+renemadsen@users.noreply.github.com>
1 parent c9d1140 commit 0f7ee2f

File tree

1 file changed

+30
-18
lines changed

1 file changed

+30
-18
lines changed

test/EFCore.MySql.FunctionalTests/Query/NorthwindWhereQueryMySqlTest.cs

Lines changed: 30 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -669,9 +669,13 @@ await AssertQuery(
669669
WHERE @__Concat_0 = `c`.`CompanyName`");
670670
}
671671

672-
public override async Task Where_bitwise_xor(bool async)
672+
[ConditionalTheory]
673+
[MemberData(nameof(IsAsyncData))]
674+
public virtual async Task Where_bitwise_xor(bool async)
673675
{
674-
await base.Where_bitwise_xor(async);
676+
await AssertQuery(
677+
async,
678+
ss => ss.Set<Customer>().Where(c => (c.CustomerID == "ALFKI") ^ true));
675679

676680
AssertSql(
677681
"""
@@ -682,6 +686,8 @@ public override async Task Where_bitwise_xor(bool async)
682686
}
683687

684688
// TODO: 9.0
689+
[ConditionalTheory]
690+
[MemberData(nameof(IsAsyncData))]
685691
[SupportedServerVersionBetweenCondition("11.4.2-mariadb", "11.5.0-mariadb", Invert = true, Skip =
686692
"""
687693
There is some strange collation behavior with MariaDB 11.4.x and this test (seems fixed in 11.5).
@@ -693,12 +699,14 @@ We changed MariaDbServerVersion.DefaultUtf8CiCollation and MariaDbServerVersion.
693699
The error is:
694700
MySqlConnector.MySqlException : Illegal mix of collations (utf8mb4_bin,NONE) and (utf8mb4_general_ci,IMPLICIT) for operation '='
695701
""")]
696-
public override Task Where_concat_string_int_comparison1(bool async)
697-
{
698-
return base.Where_concat_string_int_comparison1(async);
699-
}
702+
public virtual Task Where_concat_string_int_comparison1(bool async)
703+
=> AssertQuery(
704+
async,
705+
ss => ss.Set<Order>().Where(o => o.OrderID + 10248 == o.CustomerID));
700706

701707
// TODO: 9.0
708+
[ConditionalTheory]
709+
[MemberData(nameof(IsAsyncData))]
702710
[SupportedServerVersionBetweenCondition("11.4.2-mariadb", "11.5.0-mariadb", Invert = true, Skip =
703711
"""
704712
There is some strange collation behavior with MariaDB 11.4.x and this test (seems fixed in 11.5).
@@ -710,12 +718,14 @@ We changed MariaDbServerVersion.DefaultUtf8CiCollation and MariaDbServerVersion.
710718
The error is:
711719
MySqlConnector.MySqlException : Illegal mix of collations (utf8mb4_bin,NONE) and (utf8mb4_general_ci,IMPLICIT) for operation '='
712720
""")]
713-
public override Task Where_concat_string_int_comparison2(bool async)
714-
{
715-
return base.Where_concat_string_int_comparison2(async);
716-
}
721+
public virtual Task Where_concat_string_int_comparison2(bool async)
722+
=> AssertQuery(
723+
async,
724+
ss => ss.Set<Order>().Where(o => 10248 + o.OrderID == o.CustomerID));
717725

718726
// TODO: 9.0
727+
[ConditionalTheory]
728+
[MemberData(nameof(IsAsyncData))]
719729
[SupportedServerVersionBetweenCondition("11.4.2-mariadb", "11.5.0-mariadb", Invert = true, Skip =
720730
"""
721731
There is some strange collation behavior with MariaDB 11.4.x and this test (seems fixed in 11.5).
@@ -727,12 +737,14 @@ We changed MariaDbServerVersion.DefaultUtf8CiCollation and MariaDbServerVersion.
727737
The error is:
728738
MySqlConnector.MySqlException : Illegal mix of collations (utf8mb4_bin,NONE) and (utf8mb4_general_ci,IMPLICIT) for operation '='
729739
""")]
730-
public override Task Where_concat_string_int_comparison3(bool async)
731-
{
732-
return base.Where_concat_string_int_comparison3(async);
733-
}
740+
public virtual Task Where_concat_string_int_comparison3(bool async)
741+
=> AssertQuery(
742+
async,
743+
ss => ss.Set<Order>().Where(o => o.CustomerID == (o.OrderID + 10248)));
734744

735745
// TODO: 9.0
746+
[ConditionalTheory]
747+
[MemberData(nameof(IsAsyncData))]
736748
[SupportedServerVersionBetweenCondition("11.4.2-mariadb", "11.5.0-mariadb", Invert = true, Skip =
737749
"""
738750
There is some strange collation behavior with MariaDB 11.4.x and this test (seems fixed in 11.5).
@@ -744,10 +756,10 @@ We changed MariaDbServerVersion.DefaultUtf8CiCollation and MariaDbServerVersion.
744756
The error is:
745757
MySqlConnector.MySqlException : Illegal mix of collations (utf8mb4_bin,NONE) and (utf8mb4_general_ci,IMPLICIT) for operation '='
746758
""")]
747-
public override Task Where_concat_string_int_comparison4(bool async)
748-
{
749-
return base.Where_concat_string_int_comparison4(async);
750-
}
759+
public virtual Task Where_concat_string_int_comparison4(bool async)
760+
=> AssertQuery(
761+
async,
762+
ss => ss.Set<Order>().Where(o => o.CustomerID == (10248 + o.OrderID)));
751763

752764
// TODO: 9.0
753765
[SupportedServerVersionBetweenCondition("11.4.2-mariadb", "11.5.0-mariadb", Invert = true, Skip =

0 commit comments

Comments
 (0)