Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -438,6 +438,7 @@
</button>
<button
(click)="handleKill()"
title="Stop this run. A stopped run can't be resumed."
[disabled]="
executionState === ExecutionState.Uninitialized ||
executionState === ExecutionState.Completed ||
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1891,6 +1891,14 @@ describe("MenuComponent", () => {
expect(run).toHaveBeenCalled();
expect(kill).toHaveBeenCalled();
});

it("explains the kill button with a tooltip", () => {
fixture.detectChanges();

expect(q("button[nzdanger]").nativeElement.getAttribute("title")).toBe(
"Stop this run. A stopped run can't be resumed."
);
});
});

describe("toolbar", () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,16 @@
<div *ngIf="frameComponentConfigs.size === 0">
<nz-tab nzTitle="Result">
<div style="text-align: center">
<h4>No results available to display.</h4>
<h4 *ngIf="previewWorkflowVersion">No results available to display.</h4>
<h4 *ngIf="!previewWorkflowVersion && !currentOperatorId">No operator is selected.</h4>
<h4 *ngIf="!previewWorkflowVersion && currentOperatorId">This operator has no results yet.</h4>
<p>Tip: enable the eye icon on the operator and execute the workflow to view its results.</p>
<ng-container *ngIf="!previewWorkflowVersion">
<p *ngIf="!currentOperatorId">
Click an operator to see its results. If a run fails, its errors show here.
</p>
<p>Errors an operator hits while running show in that operator's Console.</p>
</ng-container>
</div>
</nz-tab>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -750,7 +750,46 @@ describe("ResultPanelComponent", () => {
component.frameComponentConfigs.clear();
fixture.detectChanges();

expect((fixture.nativeElement as HTMLElement).textContent).toContain("No results available to display.");
expect((fixture.nativeElement as HTMLElement).textContent).toContain("No operator is selected.");
});

it("with nothing selected, says to click an operator and where errors show", () => {
component.width = DEFAULT_WIDTH;
component.currentOperatorId = undefined;
component.frameComponentConfigs.clear();
fixture.detectChanges();

const text = (fixture.nativeElement as HTMLElement).textContent ?? "";
expect(text).toContain("No operator is selected.");
expect(text).toContain("Click an operator to see its results. If a run fails, its errors show here.");
expect(text).toContain("Errors an operator hits while running show in that operator's Console.");
expect(text).not.toContain("Click an empty spot");
});

it("with an operator already selected, does not say to click an operator", () => {
component.width = DEFAULT_WIDTH;
component.currentOperatorId = "op-1";
component.frameComponentConfigs.clear();
fixture.detectChanges();

const text = (fixture.nativeElement as HTMLElement).textContent ?? "";
expect(text).toContain("This operator has no results yet.");
expect(text).not.toContain("No operator is selected.");
expect(text).not.toContain("Click an operator");
expect(text).toContain("Errors an operator hits while running show in that operator's Console.");
});

it("while previewing a workflow version, shows no click hints", () => {
component.width = DEFAULT_WIDTH;
component.currentOperatorId = undefined;
component.previewWorkflowVersion = true;
component.frameComponentConfigs.clear();
fixture.detectChanges();

const text = (fixture.nativeElement as HTMLElement).textContent ?? "";
expect(text).toContain("No results available to display.");
expect(text).not.toContain("Click an operator");
expect(text).not.toContain("Errors an operator hits");
});

it("renders a tab per frame when frames are present", () => {
Expand Down
Loading