fix: update BootSoPartition and RemoveCacheImage component tests with new dependencies and mock data
testing/ogGui-multibranch/pipeline/head There was a failure building this commit
Details
testing/ogGui-multibranch/pipeline/head There was a failure building this commit
Details
parent
c7ed41a1a5
commit
a26f2481fa
|
|
@ -1,7 +1,5 @@
|
||||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||||
|
|
||||||
import { BootSoPartitionComponent } from './boot-so-partition.component';
|
import { BootSoPartitionComponent } from './boot-so-partition.component';
|
||||||
import {ExecuteCommandComponent} from "../execute-command.component";
|
|
||||||
import { FormBuilder, FormsModule, ReactiveFormsModule } from "@angular/forms";
|
import { FormBuilder, FormsModule, ReactiveFormsModule } from "@angular/forms";
|
||||||
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from "@angular/material/dialog";
|
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from "@angular/material/dialog";
|
||||||
import { MatFormFieldModule } from "@angular/material/form-field";
|
import { MatFormFieldModule } from "@angular/material/form-field";
|
||||||
|
|
@ -19,6 +17,8 @@ import {DataService} from "../../data.service";
|
||||||
import { provideHttpClient } from "@angular/common/http";
|
import { provideHttpClient } from "@angular/common/http";
|
||||||
import { provideHttpClientTesting } from "@angular/common/http/testing";
|
import { provideHttpClientTesting } from "@angular/common/http/testing";
|
||||||
import { ConfigService } from "@services/config.service";
|
import { ConfigService } from "@services/config.service";
|
||||||
|
import { MatExpansionModule } from '@angular/material/expansion';
|
||||||
|
import { MatDividerModule } from '@angular/material/divider';
|
||||||
|
|
||||||
describe('BootSoPartitionComponent', () => {
|
describe('BootSoPartitionComponent', () => {
|
||||||
let component: BootSoPartitionComponent;
|
let component: BootSoPartitionComponent;
|
||||||
|
|
@ -40,9 +40,11 @@ describe('BootSoPartitionComponent', () => {
|
||||||
MatInputModule,
|
MatInputModule,
|
||||||
MatCheckboxModule,
|
MatCheckboxModule,
|
||||||
MatButtonModule,
|
MatButtonModule,
|
||||||
|
MatExpansionModule,
|
||||||
MatMenuModule,
|
MatMenuModule,
|
||||||
BrowserAnimationsModule,
|
BrowserAnimationsModule,
|
||||||
MatTableModule,
|
MatTableModule,
|
||||||
|
MatDividerModule,
|
||||||
MatSelectModule,
|
MatSelectModule,
|
||||||
MatIconModule,
|
MatIconModule,
|
||||||
ToastrModule.forRoot(),
|
ToastrModule.forRoot(),
|
||||||
|
|
@ -60,7 +62,9 @@ describe('BootSoPartitionComponent', () => {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
provide: MAT_DIALOG_DATA,
|
provide: MAT_DIALOG_DATA,
|
||||||
useValue: {}
|
useValue: {
|
||||||
|
clients: []
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{ provide: ConfigService, useValue: mockConfigService }
|
{ provide: ConfigService, useValue: mockConfigService }
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||||
|
|
||||||
import { RemoveCacheImageComponent } from './remove-cache-image.component';
|
import { RemoveCacheImageComponent } from './remove-cache-image.component';
|
||||||
import {BootSoPartitionComponent} from "../boot-so-partition/boot-so-partition.component";
|
|
||||||
import { FormBuilder, FormsModule, ReactiveFormsModule } from "@angular/forms";
|
import { FormBuilder, FormsModule, ReactiveFormsModule } from "@angular/forms";
|
||||||
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from "@angular/material/dialog";
|
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from "@angular/material/dialog";
|
||||||
import { MatFormFieldModule } from "@angular/material/form-field";
|
import { MatFormFieldModule } from "@angular/material/form-field";
|
||||||
|
|
@ -19,6 +17,9 @@ import {DataService} from "../../data.service";
|
||||||
import { provideHttpClient } from "@angular/common/http";
|
import { provideHttpClient } from "@angular/common/http";
|
||||||
import { provideHttpClientTesting } from "@angular/common/http/testing";
|
import { provideHttpClientTesting } from "@angular/common/http/testing";
|
||||||
import { ConfigService } from "@services/config.service";
|
import { ConfigService } from "@services/config.service";
|
||||||
|
import { MatExpansionModule } from '@angular/material/expansion';
|
||||||
|
import { MatDividerModule } from '@angular/material/divider';
|
||||||
|
import { MatRadioModule } from '@angular/material/radio';
|
||||||
|
|
||||||
describe('RemoveCacheImageComponent', () => {
|
describe('RemoveCacheImageComponent', () => {
|
||||||
let component: RemoveCacheImageComponent;
|
let component: RemoveCacheImageComponent;
|
||||||
|
|
@ -41,9 +42,12 @@ describe('RemoveCacheImageComponent', () => {
|
||||||
MatCheckboxModule,
|
MatCheckboxModule,
|
||||||
MatButtonModule,
|
MatButtonModule,
|
||||||
MatMenuModule,
|
MatMenuModule,
|
||||||
|
MatExpansionModule,
|
||||||
BrowserAnimationsModule,
|
BrowserAnimationsModule,
|
||||||
MatTableModule,
|
MatTableModule,
|
||||||
|
MatDividerModule,
|
||||||
MatSelectModule,
|
MatSelectModule,
|
||||||
|
MatRadioModule,
|
||||||
MatIconModule,
|
MatIconModule,
|
||||||
ToastrModule.forRoot(),
|
ToastrModule.forRoot(),
|
||||||
TranslateModule.forRoot()
|
TranslateModule.forRoot()
|
||||||
|
|
@ -60,7 +64,17 @@ describe('RemoveCacheImageComponent', () => {
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
provide: MAT_DIALOG_DATA,
|
provide: MAT_DIALOG_DATA,
|
||||||
useValue: {}
|
useValue: {
|
||||||
|
clients: [
|
||||||
|
{
|
||||||
|
'@id': '/clients/1',
|
||||||
|
uuid: 'client-uuid-1',
|
||||||
|
selected: false,
|
||||||
|
status: 'og-live',
|
||||||
|
state: 'og-live'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{ provide: ConfigService, useValue: mockConfigService }
|
{ provide: ConfigService, useValue: mockConfigService }
|
||||||
]
|
]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue