Skip to content

Commit ed40509

Browse files
committed
Fix whitespace
1 parent b500dde commit ed40509

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

readthedocs/proxito/tests/test_full.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,20 @@ def test_versioned_no_slash(self):
287287
response['location'], '/en/latest/',
288288
)
289289

290+
@mock.patch('readthedocs.proxito.views.serve.get_storage_class')
291+
def test_subproject_no_slash(self, storage_mock):
292+
self.subproject.versions.update(active=True, built=True)
293+
storage_mock()().exists.return_value = False
294+
response = self.client.get(
295+
reverse('proxito_404_handler', kwargs={'proxito_path': '/projects/subproject'}),
296+
HTTP_HOST='project.readthedocs.io',
297+
)
298+
self.assertEqual(
299+
response.status_code, 302
300+
)
301+
self.assertEqual(
302+
response['location'], '/projects/subproject/',
303+
)
290304

291305
@mock.patch('readthedocs.proxito.views.serve.get_storage_class')
292306
def test_directory_indexes_readme_serving(self, storage_mock):

0 commit comments

Comments
 (0)