diff --git a/modules/ui/src/app/app.component.html b/modules/ui/src/app/app.component.html
index 38c210251..d9d1c59cf 100644
--- a/modules/ui/src/app/app.component.html
+++ b/modules/ui/src/app/app.component.html
@@ -187,7 +187,8 @@
Testrun
vm.hasConnectionSettings === true &&
vm.hasDevices &&
(!vm.systemStatus || vm.systemStatus === StatusOfTestrun.Idle) &&
- vm.isStatusLoaded === true
+ vm.isStatusLoaded === true &&
+ !vm.reports.length
">
Step 3: Once device is created, you are able to
{
expect(callout).toBeTruthy();
expect(calloutContent).toContain('Step 3');
});
+
+ it('should NOT have callout component with "Step 3" if has reports', () => {
+ store.overrideSelector(selectReports, [...HISTORY]);
+ store.refreshState();
+ fixture.detectChanges();
+
+ const callout = compiled.querySelector('app-callout');
+
+ expect(callout).toBeFalsy();
+ });
});
describe('with systemStatus data IN Progress and without riskProfiles', () => {
diff --git a/modules/ui/src/app/app.store.spec.ts b/modules/ui/src/app/app.store.spec.ts
index b25534158..10fee811b 100644
--- a/modules/ui/src/app/app.store.spec.ts
+++ b/modules/ui/src/app/app.store.spec.ts
@@ -26,6 +26,7 @@ import {
selectInterfaces,
selectIsOpenWaitSnackBar,
selectMenuOpened,
+ selectReports,
selectStatus,
selectTestModules,
} from './store/selectors';
@@ -103,6 +104,7 @@ describe('AppStore', () => {
store.overrideSelector(selectHasDevices, true);
store.overrideSelector(selectHasRiskProfiles, false);
+ store.overrideSelector(selectReports, []);
store.overrideSelector(selectHasConnectionSettings, true);
store.overrideSelector(selectMenuOpened, true);
store.overrideSelector(selectInterfaces, {});
@@ -147,6 +149,7 @@ describe('AppStore', () => {
consentShown: false,
hasDevices: true,
hasRiskProfiles: false,
+ reports: [],
isStatusLoaded: false,
systemStatus: null,
hasConnectionSettings: true,
diff --git a/modules/ui/src/app/app.store.ts b/modules/ui/src/app/app.store.ts
index a7482f064..919a5698a 100644
--- a/modules/ui/src/app/app.store.ts
+++ b/modules/ui/src/app/app.store.ts
@@ -24,6 +24,7 @@ import {
selectHasRiskProfiles,
selectInterfaces,
selectMenuOpened,
+ selectReports,
selectStatus,
} from './store/selectors';
import { Store } from '@ngrx/store';
@@ -55,6 +56,7 @@ export class AppStore extends ComponentStore {
private isStatusLoaded$ = this.select(state => state.isStatusLoaded);
private hasDevices$ = this.store.select(selectHasDevices);
private hasRiskProfiles$ = this.store.select(selectHasRiskProfiles);
+ private reports$ = this.store.select(selectReports);
private hasConnectionSetting$ = this.store.select(
selectHasConnectionSettings
);
@@ -69,6 +71,7 @@ export class AppStore extends ComponentStore {
consentShown: this.consentShown$,
hasDevices: this.hasDevices$,
hasRiskProfiles: this.hasRiskProfiles$,
+ reports: this.reports$,
isStatusLoaded: this.isStatusLoaded$,
systemStatus: this.systemStatus$,
hasConnectionSettings: this.hasConnectionSetting$,