summaryrefslogtreecommitdiff
path: root/users/test/integration/api/python/login_wrong_username.py
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2012-09-27 22:39:08 +0200
committerAzul <azul@riseup.net>2012-09-27 22:39:08 +0200
commitebbfe3d77efddbe8f97fa82c171632ac4cfcf6da (patch)
treeb81b55476f4f7889af0e346ebf5dc95afc4a02af /users/test/integration/api/python/login_wrong_username.py
parent1208257bcc0e2a6648b68433a7b7e24791f92583 (diff)
added in leap web users - one repo to rule them all
Diffstat (limited to 'users/test/integration/api/python/login_wrong_username.py')
-rwxr-xr-xusers/test/integration/api/python/login_wrong_username.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/users/test/integration/api/python/login_wrong_username.py b/users/test/integration/api/python/login_wrong_username.py
new file mode 100755
index 0000000..390f250
--- /dev/null
+++ b/users/test/integration/api/python/login_wrong_username.py
@@ -0,0 +1,19 @@
+#!/usr/bin/env python
+
+server = 'http://localhost:3000'
+
+import requests
+import json
+import string
+import random
+
+def id_generator(size=6, chars=string.ascii_uppercase + string.digits):
+ return ''.join(random.choice(chars) for x in range(size))
+
+params = {
+ 'login': 'python_test_user_'+id_generator(),
+ 'A': '12345',
+ }
+r = requests.post(server + '/sessions', data = params)
+print r.url
+print r.text