bito-code-review[bot] commented on code in PR #41424:
URL: https://github.com/apache/superset/pull/41424#discussion_r3493684986


##########
superset/reports/models.py:
##########
@@ -84,8 +84,14 @@ class ReportDataFormat(StrEnum):
     PDF = "PDF"
     PNG = "PNG"
     CSV = "CSV"
+    XLSX = "XLSX"
     TEXT = "TEXT"
 
+    @classmethod
+    def tabular(cls: type["ReportDataFormat"]) -> set["ReportDataFormat"]:
+        """Formats produced from tabular chart data via the chart export 
path."""
+        return {cls.CSV, cls.XLSX}

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Missing test for tabular() method</b></div>
   <div id="fix">
   
   The `tabular()` classmethod is a new public method introduced in this PR, 
but it lacks direct unit test coverage. Existing tests use `XLSX` directly but 
do not verify the `tabular()` method itself. Per adaptive rule [11730], new 
functionality should be covered by tests validating success paths. A test like 
`test_tabular_returns_csv_and_xlsx` would ensure this method behaves correctly 
as the canonical source of truth for tabular formats.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #99dbdf</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to