import { ComponentFixture, TestBed } from '@angular/core/testing'; import { NetworkModule } from '../network-graph.module'; import { NodeComponent } from './node.component'; import jsonData from '../Avaya_CM_Site_Survey.json'; import { Node } from '@creedinteractive/onguard-models'; const regions = jsonData.hits.hits[0]._source.Data.Regions; const sampleNodes: Node[] = []; for (const region of regions) { if (!region.Number) { continue; } sampleNodes.push(new Node(region.Number, region.Name, 'G.711MU,G.729,G.729,G.729,G.729,G.729')); } describe('NodeComponent', () => { let component: NodeComponent; let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ imports: [NetworkModule], }).compileComponents(); }); beforeEach(() => { fixture = TestBed.createComponent(NodeComponent); component = fixture.componentInstance; component.node = sampleNodes[0]; fixture.detectChanges(); }); it('should create', () => { expect(component).toBeTruthy(); }); });