UserApi_Test - test getuserbytoken with valid,invalid and empty string

CampusesApi_test -  with valid,invalid string
This commit is contained in:
etyemyer 2015-06-15 20:49:57 +03:00
parent aaa5ba223a
commit 315e07aad2

View file

@ -18,7 +18,7 @@ class UserTestPlan(unittest.TestCase):
def test_getUserByToken_invalid(self): def test_getUserByToken_invalid(self):
r = requests.get(self.__class__.url_+'api/getUserByToken/invalidtoken') r = requests.get(self.__class__.url_+'api/getUserByToken/invalidtoken')
self.assertEquals(r.status_code, 403) self.assertEquals(r.status_code, 204)
def test_getUserByToken_valid(self): def test_getUserByToken_valid(self):
@ -30,7 +30,7 @@ class UserTestPlan(unittest.TestCase):
def test_getUserByToken_empty(self): def test_getUserByToken_empty(self):
r = requests.get(self.__class__.url_+'api/getUserByToken/') r = requests.get(self.__class__.url_+'api/getUserByToken/')
self.assertEquals(r.status_code, 400) self.assertEquals(r.status_code, 400)
if __name__ == '__main__': if __name__ == '__main__':