Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/UI watt tests #64

Merged
merged 10 commits into from
Oct 14, 2021
3 changes: 3 additions & 0 deletions apps/dh-app/src/app/datahub-app.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* limitations under the License.
*/
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MATERIAL_SANITY_CHECKS } from '@angular/material/core';
import { By } from '@angular/platform-browser';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { RouterOutlet } from '@angular/router';
Expand All @@ -29,6 +30,8 @@ describe(DataHubAppComponent.name, () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [DataHubAppModule, NoopAnimationsModule, RouterTestingModule],
// https://github.com/thymikee/jest-preset-angular/issues/83
providers: [{ provide: MATERIAL_SANITY_CHECKS, useValue: false }],
dzhavat marked this conversation as resolved.
Show resolved Hide resolved
}).compileComponents();
});

Expand Down
3 changes: 3 additions & 0 deletions apps/dh-app/src/app/datahub-app.module.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* limitations under the License.
*/
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MATERIAL_SANITY_CHECKS } from '@angular/material/core';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { Router } from '@angular/router';
import { RouterTestingModule } from '@angular/router/testing';
Expand All @@ -26,6 +27,8 @@ describe('Application smoke test', () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [DataHubAppModule, NoopAnimationsModule, RouterTestingModule],
// https://github.com/thymikee/jest-preset-angular/issues/83
providers: [{ provide: MATERIAL_SANITY_CHECKS, useValue: false }],
}).compileComponents();

rootFixture = TestBed.createComponent(DataHubAppComponent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* limitations under the License.
*/
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MATERIAL_SANITY_CHECKS } from '@angular/material/core';
import { By } from '@angular/platform-browser';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { RouterTestingModule } from '@angular/router/testing';
Expand All @@ -29,6 +30,8 @@ describe(ShellComponent.name, () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [ShellModule, NoopAnimationsModule, RouterTestingModule],
// https://github.com/thymikee/jest-preset-angular/issues/83
providers: [{ provide: MATERIAL_SANITY_CHECKS, useValue: false }],
}).compileComponents();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* limitations under the License.
*/
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MATERIAL_SANITY_CHECKS } from '@angular/material/core';
import { By } from '@angular/platform-browser';
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
import { RouterTestingModule } from '@angular/router/testing';
Expand All @@ -26,6 +27,8 @@ describe(EttShellComponent.name, () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [EttShellScam, NoopAnimationsModule, RouterTestingModule],
// https://github.com/thymikee/jest-preset-angular/issues/83
providers: [{ provide: MATERIAL_SANITY_CHECKS, useValue: false }],
}).compileComponents();

fixture = TestBed.createComponent(EttShellComponent);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@ import { WattPrimaryButtonComponent } from './watt-primary-button.component';
@NgModule({
declarations: [WattPrimaryButtonComponent],
imports: [CommonModule, MatButtonModule],
entryComponents: [WattPrimaryButtonComponent],
dzhavat marked this conversation as resolved.
Show resolved Hide resolved
})
export class WattPrimaryButtonModule {}
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@ import { WattSecondaryButtonComponent } from './watt-secondary-button.component'
@NgModule({
declarations: [WattSecondaryButtonComponent],
imports: [CommonModule, MatButtonModule],
entryComponents: [WattSecondaryButtonComponent],
})
export class WattSecondaryButtonModule {}
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,6 @@ import { WattTextButtonComponent } from './watt-text-button.component';
@NgModule({
declarations: [WattTextButtonComponent],
imports: [CommonModule, MatButtonModule],
entryComponents: [WattTextButtonComponent],
})
export class WattTextButtonModule {}
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
*/
import { Component } from '@angular/core';
import { TestBed } from '@angular/core/testing';
import { MATERIAL_SANITY_CHECKS } from '@angular/material/core';

import { WattButtonModule } from './watt-button.module';

Expand All @@ -29,6 +30,8 @@ describe(WattButtonModule.name, () => {
TestBed.configureTestingModule({
declarations: [TestHostComponent],
imports: [WattButtonModule],
// https://github.com/thymikee/jest-preset-angular/issues/83
providers: [{ provide: MATERIAL_SANITY_CHECKS, useValue: false }],
});

const fixture = TestBed.createComponent(TestHostComponent);
Expand Down