Skip to content

Commit

Permalink
coverage up
Browse files Browse the repository at this point in the history
  • Loading branch information
IgorCapCoder committed Nov 27, 2023
1 parent 7df6b85 commit fbcd329
Showing 1 changed file with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import {
ContextExternalToolConfigurationTemplateResponse,
SchoolExternalToolConfigurationTemplateListResponse,
SchoolExternalToolConfigurationTemplateResponse,
ToolContextTypesList,
} from '../dto';

describe('ToolConfigurationController (API)', () => {
Expand Down Expand Up @@ -728,15 +729,20 @@ describe('ToolConfigurationController (API)', () => {

const loggedInClient: TestApiClient = await testApiClient.login(adminAccount);

return { loggedInClient };
const contextTypeList: ToolContextTypesList = new ToolContextTypesList([
ToolContextType.COURSE,
ToolContextType.BOARD_ELEMENT,
]);

return { loggedInClient, contextTypeList };
};

it('should return all context types', async () => {
const { loggedInClient } = await setup();
const { loggedInClient, contextTypeList } = await setup();

const response = await loggedInClient.get('context-types');

expect(response.body).toEqual({ data: [ToolContextType.COURSE, ToolContextType.BOARD_ELEMENT] });
expect(response.body).toEqual(contextTypeList);
});
});
});
Expand Down

0 comments on commit fbcd329

Please sign in to comment.