Added test case for run-report-form-fields component 13/100813/1
authorRupinder <rupinsi1@in.ibm.com>
Mon, 27 Jan 2020 12:29:31 +0000 (17:59 +0530)
committerRupinder <rupinsi1@in.ibm.com>
Mon, 27 Jan 2020 12:32:57 +0000 (18:02 +0530)
Written test cases for run-report-form-fields component

Issue-ID: PORTAL-808
Change-Id: If730e2ac5382d63a2a9b8a6b9eced1da6ec51eaf
Signed-off-by: Rupinder <rupinsi1@in.ibm.com>
ecomp-sdk/epsdk-app-overlay/src/main/webapp/ngapp/src/app/pages/analytics/Report_List/Report/run/run-report-form-fields/run-report-form-fields.component.spec.ts

index a273f9e..5516181 100644 (file)
@@ -22,4 +22,18 @@ describe('RunReportFormFieldsComponent', () => {
   it('should create', () => {
     expect(component).toBeTruthy();
   });
+
+  it('should test ngOnInit method', () =>{
+    component.ngOnInit();
+    expect(component.showSpinner).toEqual(true);
+    expect(component.navigateToRun).toEqual(false);
+  });
+
+  it('should test QueryString method', () =>{
+      component.directCallQueryParams == "test";
+      component.getQueryString();
+      expect(component.getQueryString).toEqual("test");
+  })
+
+
 });