Sha256: 49ff2e08889115e7e13efde1965fb30cd29ed4542a5e7bdeeb2e9269cbfcfa92

Contents?: true

Size: 486 Bytes

Versions: 1

Compression:

Stored size: 486 Bytes

Contents

#!/usr/bin/env python

server = 'http://localhost:9292'

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))

user_params = {
    'user[login]': 'python_test_user_'+id_generator(),
    'user[password_verifier]': '12345',
    'user[password_salt]': '54321'
    }
r = requests.post(server + '/users.json', data = user_params)
print r.url
print r.text

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
leap_web_users-0.0.1 test/integration/api/python/signup.py