Ejemplo n.º 1
0
 def test_put(self):
     headers = {'authorization': '930b5250fb9e23c32e8b9357d8334aa3e373ff7a'}
     json_content = {'status': 2}
     response = requests.put(self.test_url, headers=headers,
                             data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['status'], 2)
Ejemplo n.º 2
0
 def test_put(self):
     headers = {'authorization': '930b5250fb9e23c32e8b9357d8334aa3e373ff7a'}
     json_content = {'status': 2}
     response = requests.put(self.test_url,
                             headers=headers,
                             data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['status'], 2)
Ejemplo n.º 3
0
 def test_put(self):
     headers = {'Authorization': '930b5250fb9e23c32e8b9357d8334aa3e373ff7a'}
     json_content = {'name': 'f**k man', 'description': 'f**k boy'}
     response = requests.put(
         self.test_url, headers=headers, data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['name'], 'f**k man')
     self.assertEqual(response.json()['description'], 'f**k boy')
Ejemplo n.º 4
0
 def test_put(self):
     headers = {'Authorization': '930b5250fb9e23c32e8b9357d8334aa3e373ff7a'}
     json_content = {'name': 'f**k man', 'description': 'f**k boy'}
     response = requests.put(self.test_url,
                             headers=headers,
                             data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['name'], 'f**k man')
     self.assertEqual(response.json()['description'], 'f**k boy')
Ejemplo n.º 5
0
 def test_put(self):
     json_content = {'name': 'yuanbowen', 'email': '*****@*****.**'}
     response = requests.put(self.test_url, data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['name'], 'yuanbowen')
     self.assertEqual(response.json()['email'], '*****@*****.**')
Ejemplo n.º 6
0
 def test_put(self):
     json_content = {'name': 'yuanbowen', 'email': '*****@*****.**'}
     response = requests.put(self.test_url, data=json.dumps(json_content))
     self.assertEqual(response.status_code, 200)
     self.assertEqual(response.json()['name'], 'yuanbowen')
     self.assertEqual(response.json()['email'], '*****@*****.**')