1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-06-15 18:08:55 +00:00
seahub/tests/api/test_misc.py

15 lines
575 B
Python
Raw Normal View History

2014-08-28 02:21:28 +00:00
import unittest
2014-09-05 02:07:33 +00:00
from tests.api.apitestbase import ApiTestBase
2014-09-06 03:38:20 +00:00
from tests.api.urls import LIST_GROUP_AND_CONTACTS_URL
2014-09-05 02:07:33 +00:00
class MiscApiTest(ApiTestBase):
2014-09-06 03:38:20 +00:00
def test_list_group_and_contacts(self):
2014-09-05 02:07:33 +00:00
res = self.get(LIST_GROUP_AND_CONTACTS_URL).json()
self.assertIsNotNone(res)
self.assertIsInstance(res['contacts'], list)
self.assertIsNotNone(res['umsgnum'])
self.assertIsNotNone(res['replynum'])
self.assertIsInstance(res['groups'], list)
self.assertIsNotNone(res['gmsgnum'])
self.assertIsNotNone(res['newreplies'])