-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[17.0][UPD] deltatech_sale_fix_followers tests
- Loading branch information
1 parent
e87dc01
commit 882c0c5
Showing
2 changed files
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import test_sale_fix_followers |
18 changes: 18 additions & 0 deletions
18
deltatech_sale_fix_followers/tests/test_sale_fix_followers.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
from odoo.tests.common import TransactionCase | ||
|
||
|
||
class TestMailThread(TransactionCase): | ||
def setUp(self): | ||
super().setUp() | ||
|
||
# Setup test data | ||
self.partner_1 = self.env["res.partner"].create({"name": "Partner 1"}) | ||
|
||
self.subtype_1 = self.env["mail.message.subtype"].create({"name": "Subtype 1"}) | ||
|
||
self.mail_thread = self.env["mail.thread"] | ||
|
||
def test_message_subscribe(self): | ||
# Test subscribing a partner to a thread | ||
result = self.mail_thread.message_subscribe(partner_ids=[self.partner_1.id], subtype_ids=[self.subtype_1.id]) | ||
self.assertTrue(result, "Failed to subscribe partner to thread") |