Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix to #24708 - Query/Test: convert remaining complex nav collection tests to AssertQuery #25690

Merged
merged 1 commit into from
Aug 25, 2021
Merged
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

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -15,68 +15,51 @@ protected ComplexNavigationsCollectionsSharedTypeQueryTestBase(TFixture fixture)
}

public override Task Multiple_complex_includes_self_ref(bool async)
{
return Task.CompletedTask;
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "issue #13560")]
public override Task Complex_SelectMany_with_nested_navigations_and_explicit_DefaultIfEmpty_with_other_query_operators_composed_on_top(bool async)
{
return base.Complex_SelectMany_with_nested_navigations_and_explicit_DefaultIfEmpty_with_other_query_operators_composed_on_top(async);
}
=> base.Complex_SelectMany_with_nested_navigations_and_explicit_DefaultIfEmpty_with_other_query_operators_composed_on_top(async);

[ConditionalTheory(Skip = "Issue#16752")]
// include after select is not supported
public override Task Include_collection_with_multiple_orderbys_complex(bool async)
{
return base.Include_collection_with_multiple_orderbys_complex(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_collection_with_multiple_orderbys_complex_repeated(bool async)
{
return base.Include_collection_with_multiple_orderbys_complex_repeated(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_collection_with_multiple_orderbys_complex_repeated_checked(bool async)
{
return base.Include_collection_with_multiple_orderbys_complex_repeated_checked(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_collection_with_multiple_orderbys_member(bool async)
{
return base.Include_collection_with_multiple_orderbys_member(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_collection_with_multiple_orderbys_methodcall(bool async)
{
return base.Include_collection_with_multiple_orderbys_methodcall(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_collection_with_multiple_orderbys_property(bool async)
{
return base.Include_collection_with_multiple_orderbys_property(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Include_inside_subquery(bool async)
{
return base.Include_inside_subquery(async);
}
=> Task.CompletedTask;

[ConditionalTheory(Skip = "Issue#16752")]
public override Task Filtered_include_outer_parameter_used_inside_filter(bool async)
{
return base.Filtered_include_outer_parameter_used_inside_filter(async);
}
=> Task.CompletedTask;

public override Task Include_after_multiple_SelectMany_and_reference_navigation(bool async)
=> Task.CompletedTask;

public override Task Include_after_SelectMany_and_multiple_reference_navigations(bool async)
=> Task.CompletedTask;

public override Task Required_navigation_with_Include(bool async)
=> Task.CompletedTask;

public override Task Required_navigation_with_Include_ThenInclude(bool async)
=> Task.CompletedTask;

// Navigations used are not mapped in shared type.
public override Task SelectMany_DefaultIfEmpty_multiple_times_with_joins_projecting_a_collection(bool async)
{
// Navigations used are not mapped in shared type.
return Task.CompletedTask;
}
=> Task.CompletedTask;
}
}
40 changes: 0 additions & 40 deletions test/EFCore.Specification.Tests/Query/GearsOfWarQueryTestBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5842,46 +5842,6 @@ public virtual Task GroupBy_Property_Include_Aggregate_with_anonymous_selector(b
assertOrder: true);
}

[ConditionalTheory(Skip = "issue #16752")]
[MemberData(nameof(IsAsyncData))]
public virtual Task Group_by_entity_key_with_include_on_that_entity_with_key_in_result_selector(bool async)
{
return AssertQuery(
async,
ss => ss.Set<Gear>()
.GroupBy(g => g.CityOfBirth)
.OrderBy(g => g.Key.Name)
.Select(g => g.Key)
.Include(c => c.BornGears).ThenInclude(g => g.Weapons),
assertOrder: true,
elementAsserter: (e, a) =>
{
Assert.Equal(e.Name, a.Name);
Assert.Equal(e.BornGears == null, a.BornGears == null);
Assert.Equal(e.BornGears.Count(), a.BornGears.Count());
});
}

[ConditionalTheory(Skip = "issue #16752")]
[MemberData(nameof(IsAsyncData))]
public virtual Task Group_by_entity_key_with_include_on_that_entity_with_key_in_result_selector_using_EF_Property(bool async)
{
return AssertQuery(
async,
ss => ss.Set<Gear>()
.GroupBy(g => g.CityOfBirth)
.OrderBy(g => g.Key.Name)
.Select(g => EF.Property<City>(g, "Key"))
.Include(c => c.BornGears).ThenInclude(g => g.Weapons),
assertOrder: true,
elementAsserter: (e, a) =>
{
Assert.Equal(e.Name, a.Name);
Assert.Equal(e.BornGears == null, a.BornGears == null);
Assert.Equal(e.BornGears.Count(), a.BornGears.Count());
});
}

[ConditionalTheory]
[MemberData(nameof(IsAsyncData))]
public virtual Task Group_by_with_include_with_entity_in_result_selector(bool async)
Expand Down
Loading