PG1204 commented on code in PR #6075:
URL: https://github.com/apache/texera/pull/6075#discussion_r3563007482
##########
frontend/src/app/workspace/component/workflow-editor/workflow-editor.component.spec.ts:
##########
@@ -967,6 +966,20 @@ describe("WorkflowEditorComponent", () => {
expect(getStroke(mockScanPredicate.operatorID)).toBe("red");
});
+
+ it("supplies a computed Validation from the operator-add path", () => {
+ // The operator-add subscriber now obtains the Validation itself (via
+ // validateOperator) and forwards it to applyOperatorBorder, so the
+ // helper's parameter can stay required with no fallback recompute.
+ vi.spyOn(workflowStatusService,
"getCurrentStatus").mockReturnValue({});
+ vi.spyOn(validationWorkflowService,
"validateOperator").mockReturnValue({ isValid: true });
+ const applyBorderSpy = vi.spyOn(component as any,
"applyOperatorBorder");
+
+ workflowActionService.addOperator(mockScanPredicate, mockPoint);
+ fixture.detectChanges();
+
+
expect(applyBorderSpy).toHaveBeenCalledWith(mockScanPredicate.operatorID, {
isValid: true });
Review Comment:
address in
[cc4243f](https://github.com/apache/texera/pull/6075/commits/cc4243f8eec355f0bceedd90be12f7d801f2d9c4)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]