adding collapse module to testing components.

This commit is contained in:
Jason Kulatunga 2023-01-16 10:08:08 -08:00
parent d8cc91d1d0
commit d972f1fab1
10 changed files with 38 additions and 13 deletions

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { AllergyIntoleranceComponent } from './allergy-intolerance.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('AllergyIntoleranceComponent', () => {
let component: AllergyIntoleranceComponent;
@ -8,7 +9,8 @@ describe('AllergyIntoleranceComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ AllergyIntoleranceComponent ]
declarations: [ AllergyIntoleranceComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { BinaryComponent } from './binary.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('BinaryComponent', () => {
let component: BinaryComponent;
@ -8,7 +9,9 @@ describe('BinaryComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ BinaryComponent ]
declarations: [ BinaryComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { DiagnosticReportComponent } from './diagnostic-report.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('DiagnosticReportComponent', () => {
let component: DiagnosticReportComponent;
@ -8,7 +9,9 @@ describe('DiagnosticReportComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ DiagnosticReportComponent ]
declarations: [ DiagnosticReportComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ImmunizationComponent } from './immunization.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('ImmunizationComponent', () => {
let component: ImmunizationComponent;
@ -8,7 +9,9 @@ describe('ImmunizationComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ ImmunizationComponent ]
declarations: [ ImmunizationComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MedicationRequestComponent } from './medication-request.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('MedicationRequestComponent', () => {
let component: MedicationRequestComponent;
@ -8,7 +9,9 @@ describe('MedicationRequestComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ MedicationRequestComponent ]
declarations: [ MedicationRequestComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { MedicationComponent } from './medication.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('MedicationComponent', () => {
let component: MedicationComponent;
@ -8,7 +9,9 @@ describe('MedicationComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ MedicationComponent ]
declarations: [ MedicationComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,6 +1,7 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { PractitionerComponent } from './practitioner.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
describe('PractitionerComponent', () => {
let component: PractitionerComponent;
@ -8,7 +9,9 @@ describe('PractitionerComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ PractitionerComponent ]
declarations: [ PractitionerComponent ],
imports: [NgbCollapseModule]
})
.compileComponents();

View File

@ -1,10 +1,10 @@
<div class="card card-fhir-resource" >
<div class="card card-fhir-resource">
<div class="card-header" (click)="isCollapsed = ! isCollapsed">
<div>
<h6 class="card-title">{{displayModel.display}}</h6>
<p class="card-text tx-gray-400" *ngIf="displayModel.performed_datetime"><strong>Start date</strong> {{displayModel.performed_datetime | date}}</p>
<h6 class="card-title">{{displayModel?.display}}</h6>
<p class="card-text tx-gray-400" *ngIf="displayModel?.performed_datetime"><strong>Start date</strong> {{displayModel?.performed_datetime | date}}</p>
</div>
<fhir-ui-badge class="float-right" [status]="displayModel.status">{{displayModel.status}}</fhir-ui-badge>
<fhir-ui-badge class="float-right" [status]="displayModel?.status">{{displayModel?.status}}</fhir-ui-badge>
<!-- <div class="btn-group">-->
<!-- <button class="btn active">Day</button>-->
<!-- <button class="btn">Week</button>-->

View File

@ -1,6 +1,8 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ProcedureComponent } from './procedure.component';
import {NgbCollapseModule} from '@ng-bootstrap/ng-bootstrap';
import {RouterTestingModule} from '@angular/router/testing';
describe('ProcedureComponent', () => {
let component: ProcedureComponent;
@ -8,7 +10,10 @@ describe('ProcedureComponent', () => {
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ ProcedureComponent ]
declarations: [ ProcedureComponent ],
imports: [NgbCollapseModule],
providers: [RouterTestingModule]
})
.compileComponents();

View File

@ -5,7 +5,7 @@ import {Router} from '@angular/router';
import {ProcedureModel} from '../../../../../lib/models/resources/procedure-model';
@Component({
selector: 'app-procedure',
selector: 'fhir-procedure',
templateUrl: './procedure.component.html',
styleUrls: ['./procedure.component.scss']
})