summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk/epsdk-app-overlay/src
diff options
context:
space:
mode:
Diffstat (limited to 'ecomp-sdk/epsdk-app-overlay/src')
-rw-r--r--ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/definition/definition.service.spec.ts32
1 files changed, 29 insertions, 3 deletions
diff --git a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/definition/definition.service.spec.ts b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/definition/definition.service.spec.ts
index 1c56d381..74dc8b5e 100644
--- a/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/definition/definition.service.spec.ts
+++ b/ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/definition/definition.service.spec.ts
@@ -2,15 +2,41 @@ import { TestBed } from '@angular/core/testing';
import { DefinitionService } from './definition.service';
import { HttpClientTestingModule } from '@angular/common/http/testing';
+import { HttpClientModule } from '@angular/common/http';
+import { environment } from 'src/environments/environment';
describe('DefinitionServiceService', () => {
- beforeEach(() =>
+
+let service:DefinitionService;
+
+ beforeEach(() =>{
TestBed.configureTestingModule({
- imports: [HttpClientTestingModule]
- }));
+ imports: [HttpClientTestingModule],
+ providers:[HttpClientModule,DefinitionService]
+ })
+ service=TestBed.get(DefinitionService);
+});
it('should be created', () => {
const service: DefinitionService = TestBed.get(DefinitionService);
expect(service).toBeTruthy();
});
+
+ it('should get getDefinitionPageDetails', () => {
+ let IncomingReportId : number;
+ let reportMode: string;
+ service.getDefinitionPageDetails(IncomingReportId,reportMode).subscribe((resp) => {
+ expect(resp).toBe(environment.baseUrl+IncomingReportId);
+ });
+ })
+
+ it('should get portDefinitionPageDetails', () => {
+ let IncomingReportId: number;
+ let finalPostObj : any;
+ service.portDefinitionPageDetails(IncomingReportId,finalPostObj).subscribe((resp) => {
+ expect(resp).toBe(environment.baseUrl+IncomingReportId);
+ });
+ })
+
+
});