mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-04-28 17:32:38 +02:00
Check that project creation via the API doesn't required a captcha. (#926)
Fixes #922
This commit is contained in:
parent
beac10be0b
commit
2adc2bf0be
1 changed files with 13 additions and 0 deletions
|
@ -285,6 +285,19 @@ class CaptchaTestCase(IhatemoneyTestCase):
|
|||
)
|
||||
assert len(models.Project.query.all()) == 1
|
||||
|
||||
def test_api_project_creation_does_not_need_captcha(self):
|
||||
resp = self.client.post(
|
||||
"/api/projects",
|
||||
data={
|
||||
"name": "raclette",
|
||||
"id": "raclette",
|
||||
"password": "raclette",
|
||||
"contact_email": "raclette@notmyidea.org",
|
||||
},
|
||||
)
|
||||
self.assertTrue(resp.status, 201)
|
||||
assert len(models.Project.query.all()) == 1
|
||||
|
||||
|
||||
class TestCurrencyConverter(unittest.TestCase):
|
||||
converter = CurrencyConverter()
|
||||
|
|
Loading…
Reference in a new issue