Skip to content

Commit

Permalink
Fixed notify test
Browse files Browse the repository at this point in the history
  • Loading branch information
imolorhe committed Jun 20, 2020
1 parent 3bc1c1e commit a32fda3
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/altair-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"start": "ng serve",
"build": "npm run generate-settings-schema-validator && node --max_old_space_size=8000 ./node_modules/@angular/cli/bin/ng build --prod --aot --stats-json",
"test-single-run": "ng test --watch=false --code-coverage",
"test": "jest",
"test": "jest && ng lint",
"test:watch": "jest --watch",
"prepare": "npm run generate-settings-schema-validator && node --max_old_space_size=8000 ./node_modules/@angular/cli/bin/ng build --outputHashing=none --prod --aot --stats-json",
"test-build": "ng lint && npm run build && npm run test-single-run",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ describe('NotifyService', () => {
warning: anyFn(),
info: anyFn(),
});
mockToastrService = mock();
mockStore = mock();
TestBed.configureTestingModule({
providers: [
Expand Down
2 changes: 1 addition & 1 deletion packages/altair-app/src/testing/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
type AnyFunction = (...args: any[]) => any;
export const anyFn = (): AnyFunction => jest.fn();
export const anyFn = () => jest.fn() as AnyFunction;
export function mock<T>(obj: Partial<T> = {}): T {
return obj as T;
}

0 comments on commit a32fda3

Please sign in to comment.