test: Updated router unit tests.
Signed-off-by: Marley Powell <Marley.Powell@exclaimer.com>
This commit is contained in:
@@ -49,6 +49,8 @@ describe('createRouter', () => {
|
||||
getPullRequests: jest.fn(),
|
||||
getBuilds: jest.fn(),
|
||||
getBuildRuns: jest.fn(),
|
||||
getAllTeams: jest.fn().mockReturnValue([]),
|
||||
getTeamMembers: jest.fn(),
|
||||
} as any;
|
||||
const router = await createRouter({
|
||||
azureDevOpsApi,
|
||||
@@ -406,4 +408,11 @@ describe('createRouter', () => {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
describe('GET /users/:userId/team-ids', () => {
|
||||
it('fetches a a list of teams', async () => {
|
||||
const response = await request(app).get('/users/user1/team-ids');
|
||||
expect(response.status).toEqual(200);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user