[FIX] docuseal_signing: clean up server action and translate notifications
- Deleting a ``docuseal.template`` now removes its generated contextual server action; an orphaned action would browse a deleted template at runtime and crash. - The display notification strings are wrapped in ``_()`` so they are translatable, with their French translations in the catalog. - Add a short manifest description so the Apps page renders plain text instead of parsing the markdown README as reStructuredText. Covered by a unit test on the template deletion lifecycle. Assisted-By: GLM-5.3-Flash
This commit is contained in:
@@ -1 +1,2 @@
|
||||
from . import test_fetch_fields
|
||||
from . import test_server_action
|
||||
|
||||
19
docuseal_signing/tests/test_server_action.py
Normal file
19
docuseal_signing/tests/test_server_action.py
Normal file
@@ -0,0 +1,19 @@
|
||||
from odoo.tests import TransactionCase
|
||||
|
||||
|
||||
class TestServerAction(TransactionCase):
|
||||
"""Lifecycle of the generated contextual server action."""
|
||||
|
||||
def test_unlink_removes_server_action(self):
|
||||
"""Deleting a template removes its generated server action,
|
||||
instead of leaving an orphaned action browsing a dead record."""
|
||||
template = self.env["docuseal.template"].create({
|
||||
"name": "Contract",
|
||||
"template_id": 123,
|
||||
})
|
||||
template.action_create_server_action()
|
||||
action = template.server_action_id
|
||||
self.assertTrue(action.exists())
|
||||
|
||||
template.unlink()
|
||||
self.assertFalse(action.exists())
|
||||
Reference in New Issue
Block a user