Files
Lucas Lefèvre a7fe381f71 [REF] spreadsheet_dashboard: remove badly named raw field
Up until now, the collaborative expected a field named `raw` containing
the serialized json data. This is historic and appeared because the field
containing the existing field `raw` on `document.document` contained this
data.

The name `raw` is meaningless. Now the collaborative expects a field
named `spreadsheet_data`.
I chose a field over a custom method because fields are more broadly
supported everywhere (web client services, web client mocks)

closes odoo/odoo#104167

Related: odoo/upgrade#4005
Related: odoo/enterprise#33246
Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
2023-01-20 20:58:01 +01:00

15 lines
585 B
Python

from odoo.addons.spreadsheet.tests.validate_spreadsheet_data import (
ValidateSpreadsheetData,
)
from odoo.tests.common import tagged
@tagged("-at_install", "post_install")
class TestSpreadsheetDashboardData(ValidateSpreadsheetData):
def test_validate_dashboard_data(self):
"""validate fields and models used in dashboards"""
dashboards = self.env["spreadsheet.dashboard"].search([])
for dashboard in dashboards:
with self.subTest(dashboard.name):
self.validate_spreadsheet_data(dashboard.spreadsheet_data, dashboard.name)