Skip to content

Commit

Permalink
test: correct nested include filter tests #259
Browse files Browse the repository at this point in the history
  • Loading branch information
Viktor Bozhinov committed Dec 9, 2021
1 parent d2b3826 commit 3f6bd7d
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions test/search_api/test_search_api_query_filter_factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -1665,8 +1665,8 @@ def test_valid_include_filter(
},
},
"documents",
4,
[["datasets"], ["datasets.instrument"]],
3,
[["datasets.instrument"]],
[
SearchAPIWhereFilter("datasets.title", "Dataset 1", "eq"),
SearchAPIWhereFilter(
Expand Down Expand Up @@ -1722,8 +1722,8 @@ def test_valid_include_filter_with_where_filter_in_scope(
},
},
"documents",
2,
[["datasets"], ["datasets.parameters"]],
1,
[["datasets.parameters"]],
id="Single related model",
),
pytest.param(
Expand All @@ -1743,8 +1743,8 @@ def test_valid_include_filter_with_where_filter_in_scope(
},
},
"documents",
3,
[["datasets"], ["datasets.parameters"], ["datasets.instrument"]],
2,
[["datasets.parameters"], ["datasets.instrument"]],
id="Multiple related models",
),
pytest.param(
Expand All @@ -1768,12 +1768,8 @@ def test_valid_include_filter_with_where_filter_in_scope(
},
},
"instruments",
3,
[
["datasets"],
["datasets.documents"],
["datasets.documents.parameters"],
],
1,
[["datasets.documents.parameters"]],
id="Nested related models",
),
],
Expand Down

0 comments on commit 3f6bd7d

Please sign in to comment.