summaryrefslogtreecommitdiff
path: root/patchwork
diff options
context:
space:
mode:
authorStephen Finucane <stephen@that.guru>2020-04-16 00:43:40 +0100
committerStephen Finucane <stephen@that.guru>2020-04-18 11:57:28 +0100
commit48f27d587874414df95a03f7ab338f0f029de7db (patch)
tree00656b58ce156f9ee90b29c28a013b2183a727d9 /patchwork
parent2047107468a1d78daf2e917ddce1253b38ea23ea (diff)
downloadpatchwork-48f27d587874414df95a03f7ab338f0f029de7db.tar
patchwork-48f27d587874414df95a03f7ab338f0f029de7db.tar.gz
docs: Resolve issues with 'projects'
Two issues here: - The ID in '/projects/{id}' can be either an integer or a string. - We were attempting to validate an invalid request. Signed-off-by: Stephen Finucane <stephen@that.guru>
Diffstat (limited to 'patchwork')
-rw-r--r--patchwork/tests/api/test_project.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/patchwork/tests/api/test_project.py b/patchwork/tests/api/test_project.py
index 5a76767..bf87a56 100644
--- a/patchwork/tests/api/test_project.py
+++ b/patchwork/tests/api/test_project.py
@@ -196,8 +196,11 @@ class TestProjectAPI(utils.APITestCase):
user = create_maintainer(project)
self.client.force_authenticate(user=user)
- resp = self.client.patch(self.api_url(project.id), {
- 'link_name': 'test'})
+ resp = self.client.patch(
+ self.api_url(project.id),
+ {'link_name': 'test'},
+ validate_request=False,
+ )
# NOTE(stephenfin): This actually returns HTTP 200 due to
# https://github.com/encode/django-rest-framework/issues/1655
self.assertEqual(status.HTTP_200_OK, resp.status_code)