Yicong-Huang opened a new pull request, #4809: URL: https://github.com/apache/texera/pull/4809
### What changes were proposed in this PR? Adds scalatest coverage for four visualization operator descriptors under `common/workflow-operator/.../visualization/`. The existing thin spec on `ImageVisualizerOpDesc` is extended; specs for `FunnelPlotOpDesc`, `VolcanoPlotOpDesc`, and `BulletChartOpDesc` are new. The specs verify (per OpDesc) the user-friendly name + group + outputPorts wiring, the single-port `html-content` STRING schema returned by `getOutputSchemas`, the rendered Python source from `generatePythonCode` (operator class + plotly imports + `decode_python_template` runtime decode sites for each `EncodableString` field), and the missing-required-field assertion behavior — which differs by OpDesc: - `ImageVisualizerOpDesc.binaryContent` defaults to `null` (`var ... = _`), so the assert path raises `NullPointerException` when called on null. - `FunnelPlotOpDesc.x` / `.y` default to `""`, so the same assert raises `AssertionError`. - `VolcanoPlotOpDesc` and `BulletChartOpDesc` have no asserts in `generatePythonCode` — empty defaults render valid Python source. ### Any related issues, documentation, discussions? Closes #4807. Bug filed separately: most visualization OpDescs (29 files) have a duplicate `Map(operatorInfo.outputPorts.head.id -> outputSchema)` statement in `getOutputSchemas` — the first call is computed and discarded, only the second is the actual return value. Likely a copy-paste artifact. ### How was this PR tested? ``` sbt scalafmtCheckAll sbt "WorkflowOperator/testOnly org.apache.texera.amber.operator.visualization.ImageViz.ImageVisualizerOpDescSpec org.apache.texera.amber.operator.visualization.funnelPlot.FunnelPlotOpDescSpec org.apache.texera.amber.operator.visualization.volcanoPlot.VolcanoPlotOpDescSpec org.apache.texera.amber.operator.visualization.bulletChart.BulletChartOpDescSpec" ``` ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (claude-opus-4-7) -- 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]
