Skip to content
Snippets Groups Projects
Commit 3b776e49 authored by Harshith DS's avatar Harshith DS
Browse files

TMSS-1694:Added tests

parent 4ab92290
No related branches found
No related tags found
1 merge request!923Resolve TMSS-1694
......@@ -23,7 +23,7 @@ import AuthServiceMock from '../../__mocks__/auth.service.data';
let projectListSpy, scheduleSetListSpy, observStrategiesSpy, taskTemplatesSpy, saveSUFromStrategySpy, updateSUSpy, createSUTasksSpy,
utilSpy, utcSpy, taskFilterDefSpy, suConstraintTemplateSpy, allTaskRelationSpy, stationGroupSpy, stationSpy,
userPermissionSpy, authPermissionSpy, scheduleSetByIdSpy, templatePurposesSpy, templateStatesSpy;
userPermissionSpy, authPermissionSpy, scheduleSetByIdSpy, templatePurposesSpy, templateStatesSpy, rolesSpy;
jest.setTimeout(120000);
beforeEach(() => {
......@@ -97,6 +97,8 @@ const setMockSpy = () => {
scheduleSetByIdSpy = jest.spyOn(ScheduleService, 'getSchedulingBySet');
scheduleSetByIdSpy.mockImplementation((value) => { return Promise.resolve(SUServiceMock.getSchedulingBySet)});
rolesSpy = jest.spyOn(ProjectService, 'getMyRoles');
rolesSpy.mockImplementation((model) => { return Promise.resolve(SUServiceMock.getMyRoles)});
}
const clearMockSpy = () => {
......@@ -115,6 +117,7 @@ const clearMockSpy = () => {
stationGroupSpy.mockRestore();
stationSpy.mockRestore();
scheduleSetByIdSpy.mockRestore();
rolesSpy.mockRestore();
}
it("renders SU Set create page with all fields and default values", async() => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment