Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
franzmueller committed Dec 1, 2023
1 parent fe37e4b commit 12593ec
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/app/modules/data/flow-repo/flow-repo.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import { FlowEngineService } from './shared/flow-engine.service';
import { By } from '@angular/platform-browser';
import { FlowModel } from './shared/flow.model';
import { of } from 'rxjs';
import { CostService } from '../../cost/shared/cost.service';

describe('FlowRepoComponent', () => {
let component: FlowRepoComponent;
Expand All @@ -40,6 +41,9 @@ describe('FlowRepoComponent', () => {
flowRepoServiceSpy.userHasUpdateAuthorization.and.returnValue(true);
flowRepoServiceSpy.userHasReadAuthorization.and.returnValue(true);

const costServiceSpy: Spy<CostService> = createSpyFromClass(CostService);
costServiceSpy.userMayGetFlowCostEstimations.and.returnValue(false);

var testFlow: FlowModel = {
_id: 'string',
name: "string",
Expand All @@ -66,6 +70,7 @@ describe('FlowRepoComponent', () => {
{ provide: AuthorizationService, useClass: AuthorizationServiceMock },
{ provide: FlowRepoService, useValue: flowRepoServiceSpy },
{ provide: FlowEngineService, useValue: flowEngineServiceSpy },
{ provide: CostService, useValue: costServiceSpy },
DialogsService
],
}).compileComponents();
Expand Down

0 comments on commit 12593ec

Please sign in to comment.