]> git.apps.os.sepia.ceph.com Git - ceph.git/blob
afce56a2bacf8c224e4da13d8ce107850def2919
[ceph.git] /
1 import { async, ComponentFixture, TestBed } from '@angular/core/testing';
2
3 import { TabsModule } from 'ngx-bootstrap/tabs';
4
5 import { CdTableSelection } from '../../../shared/models/cd-table-selection';
6 import { SharedModule } from '../../../shared/shared.module';
7 import { PerformanceCounterModule } from '../../performance-counter/performance-counter.module';
8 import { RgwDaemonService } from '../services/rgw-daemon.service';
9 import { RgwDaemonDetailsComponent } from './rgw-daemon-details.component';
10
11 describe('RgwDaemonDetailsComponent', () => {
12   let component: RgwDaemonDetailsComponent;
13   let fixture: ComponentFixture<RgwDaemonDetailsComponent>;
14
15   const fakeService = {
16     get: (id: string) => {
17       return new Promise(function(resolve, reject) {
18         return [];
19       });
20     }
21   };
22
23   beforeEach(async(() => {
24     TestBed.configureTestingModule({
25       declarations: [ RgwDaemonDetailsComponent ],
26       imports: [
27         SharedModule,
28         PerformanceCounterModule,
29         TabsModule.forRoot()
30       ],
31       providers: [{ provide: RgwDaemonService, useValue: fakeService }]
32     });
33   }));
34
35   beforeEach(() => {
36     fixture = TestBed.createComponent(RgwDaemonDetailsComponent);
37     component = fixture.componentInstance;
38
39     component.selection = new CdTableSelection();
40
41     fixture.detectChanges();
42   });
43
44   it('should create', () => {
45     expect(component).toBeTruthy();
46   });
47 });