Merge pull request #318 from coreos-inc/reallyfixlogs
Fix logs view and API
This commit is contained in:
commit
5c213df835
3 changed files with 39 additions and 14 deletions
|
@ -35,7 +35,7 @@ from endpoints.api.user import (PrivateRepositories, ConvertToOrganization, Sign
|
|||
|
||||
from endpoints.api.repotoken import RepositoryToken, RepositoryTokenList
|
||||
from endpoints.api.prototype import PermissionPrototype, PermissionPrototypeList
|
||||
from endpoints.api.logs import UserLogs, OrgLogs
|
||||
from endpoints.api.logs import UserLogs, OrgLogs, OrgAggregateLogs, UserAggregateLogs
|
||||
from endpoints.api.billing import (UserCard, UserPlan, ListPlans, OrganizationCard,
|
||||
OrganizationPlan)
|
||||
from endpoints.api.discovery import DiscoveryResource
|
||||
|
@ -2569,6 +2569,20 @@ class TestLogs(ApiTestCase):
|
|||
assert 'start_time' in json
|
||||
assert 'end_time' in json
|
||||
|
||||
def test_user_aggregate_logs(self):
|
||||
self.login(ADMIN_ACCESS_USER)
|
||||
|
||||
json = self.getJsonResponse(UserAggregateLogs)
|
||||
assert 'aggregated' in json
|
||||
|
||||
|
||||
def test_org_logs(self):
|
||||
self.login(ADMIN_ACCESS_USER)
|
||||
|
||||
json = self.getJsonResponse(OrgAggregateLogs, params=dict(orgname=ORGANIZATION))
|
||||
assert 'aggregated' in json
|
||||
|
||||
|
||||
def test_performer(self):
|
||||
self.login(ADMIN_ACCESS_USER)
|
||||
|
||||
|
|
Reference in a new issue