"git@gitlab.lam.fr:anis/anis-next.git" did not exist on "6ed74daf874da2000d7490e30ff16fd76516b932"
Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
import { TestBed, waitForAsync, ComponentFixture } from '@angular/core/testing';
import { RouterTestingModule } from '@angular/router/testing';
import { OutputListComponent } from './output-list.component';
import { Attribute } from '../../../metamodel/models';
const ATTRIBUTE_LIST: Attribute[] = [
{
id: 2,
name: 'name_two',
label: 'label_two',
form_label: 'form_label_two',
description : 'description_two',
output_display: 1,
criteria_display: 1,
search_flag : 'SPECTRUM_1D',
search_type : 'field',
operator : '=',
type: '',
display_detail: 1
},
{
id: 1,
name: 'name_one',
label: 'label_one',
form_label: 'form_label_one',
description: 'description_one',
output_display: 2,
criteria_display: 2,
search_flag: 'ID',
search_type: 'field',
operator: '=',
type: 'integer',
display_detail: 2
}
];
describe('OutputListComponent', () => {
let component: OutputListComponent;
let fixture: ComponentFixture<OutputListComponent>;
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
imports: [RouterTestingModule],
declarations: [OutputListComponent]
}).compileComponents();
fixture = TestBed.createComponent(OutputListComponent);
component = fixture.componentInstance;
}));
it('should create the component', () => {
expect(component).toBeDefined();
});
it('should information in HTML file', () => {
component.datasetSelected = 'myTestDataset';
component.attributeList = ATTRIBUTE_LIST;
fixture.detectChanges();
expect(fixture).toMatchSnapshot();
});
});