Skip to content

Commit

Permalink
Re-enable tests for issue#16057
Browse files Browse the repository at this point in the history
Let's see if we still have discrepancies

Resolves #16057
  • Loading branch information
smitpatel committed Aug 28, 2020
1 parent a29f30c commit a89e329
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2422,11 +2422,12 @@ public override async Task Where_datetimeoffset_date_component(bool async)
{
await base.Where_datetimeoffset_date_component(async);

// issue #16057
// AssertSql(
// @"SELECT [m].[Id], [m].[CodeName], [m].[Rating], [m].[Timeline]
//FROM [Missions] AS [m]
//WHERE CONVERT(date, [m].[Timeline]) > '0001-01-01T00:00:00.0000000-08:00'");
AssertSql(
@"@__Date_0='0001-01-01T00:00:00.0000000'
SELECT [m].[Id], [m].[CodeName], [m].[Duration], [m].[Rating], [m].[Timeline]
FROM [Missions] AS [m]
WHERE CONVERT(date, [m].[Timeline]) > @__Date_0");
}

public override async Task Where_datetimeoffset_year_component(bool async)
Expand Down
15 changes: 7 additions & 8 deletions test/EFCore.SqlServer.FunctionalTests/Query/QueryBugsTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -840,14 +840,13 @@ private void Execute1742(CustomerDetails_1742 details)
var firstName = details.FirstName;
ctx.Customers.Where(c => c.FirstName == firstName && c.LastName == details.LastName).ToList();

// issue #16057
// AssertSql(
// @"@__firstName_0='Foo' (Size = 450)
//@__8__locals1_details_LastName_1='Bar' (Size = 450)

//SELECT [c].[FirstName], [c].[LastName]
//FROM [Customer] AS [c]
//WHERE (([c].[FirstName] = @__firstName_0) AND @__firstName_0 IS NOT NULL) AND (([c].[LastName] = @__8__locals1_details_LastName_1) AND @__8__locals1_details_LastName_1 IS NOT NULL)");
AssertSql(
@"@__firstName_0='Foo' (Size = 450)
@__8__locals1_details_LastName_1='Bar' (Size = 450)
SELECT [c].[FirstName], [c].[LastName]
FROM [Customer] AS [c]
WHERE ([c].[FirstName] = @__firstName_0) AND ([c].[LastName] = @__8__locals1_details_LastName_1)");
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2896,11 +2896,12 @@ public override async Task Where_datetimeoffset_date_component(bool async)
{
await base.Where_datetimeoffset_date_component(async);

// issue #16057
// AssertSql(
// @"SELECT [m].[Id], [m].[CodeName], [m].[Rating], [m].[Timeline]
//FROM [Missions] AS [m]
//WHERE CONVERT(date, [m].[Timeline]) > '0001-01-01T00:00:00.0000000-08:00'");
AssertSql(
@"@__Date_0='0001-01-01T00:00:00.0000000'
SELECT [m].[Id], [m].[CodeName], [m].[Duration], [m].[Rating], [m].[Timeline]
FROM [Missions] AS [m]
WHERE CONVERT(date, [m].[Timeline]) > @__Date_0");
}

public override async Task Where_datetimeoffset_year_component(bool async)
Expand Down

0 comments on commit a89e329

Please sign in to comment.