Skip to content

Commit 4b40524

Browse files
committed
Tests
1 parent 7cf122c commit 4b40524

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

readthedocs/search/tests/test_api.py

+2
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ def test_doc_search_filter_by_version(self, api_client, project):
182182
data = resp.data['results']
183183
assert len(data) == 1
184184
assert data[0]['project'] == project.slug
185+
assert data[0]['project_alias'] is None
185186

186187
def test_doc_search_pagination(self, api_client, project):
187188
"""Test Doc search result can be paginated"""
@@ -264,6 +265,7 @@ def test_doc_search_subprojects(self, api_client, all_projects):
264265
# First result should be the subproject
265266
first_result = data[0]
266267
assert first_result['project'] == subproject.slug
268+
assert first_result['project_alias'] == subproject.slug
267269
# The result is from the same version as the main project.
268270
assert first_result['version'] == version.slug
269271
# Check the link is the subproject document link

0 commit comments

Comments
 (0)