Skip to content

Commit

Permalink
[MIG] document_page_group: Migration to 17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
peluko00 committed Jun 18, 2024
1 parent 05ea367 commit bc8c59f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion document_page_group/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"name": "Document Page Group",
"summary": """
Define access groups on documents""",
"version": "16.0.1.0.1",
"version": "17.0.1.0.0",
"license": "AGPL-3",
"author": "Creu Blanca,Odoo Community Association (OCA)",
"website": "https://github.com/OCA/knowledge",
Expand Down
21 changes: 11 additions & 10 deletions document_page_group/tests/test_document_page_group.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,28 @@


class TestDocumentPageGroup(TransactionCase):
def setUp(self):
super().setUp()
knowledge_group = self.browse_ref("document_knowledge.group_document_user").id
self.user_id = self.env["res.users"].create(
@classmethod
def setUpClass(cls):
super().setUpClass()
knowledge_group = cls.env.ref("document_knowledge.group_document_user").id
cls.user_id = cls.env["res.users"].create(
{
"name": "user",
"login": "login",
"email": "email",
"groups_id": [(4, knowledge_group)],
}
)
self.group = self.browse_ref("document_page.group_document_manager")
cls.group = cls.env.ref("document_page.group_document_manager")

self.categ_1 = self.env["document.page"].create(
cls.categ_1 = cls.env["document.page"].create(
{"name": "Categ 1", "type": "category"}
)
self.categ_2 = self.env["document.page"].create(
{"name": "Categ 2", "type": "category", "parent_id": self.categ_1.id}
cls.categ_2 = cls.env["document.page"].create(
{"name": "Categ 2", "type": "category", "parent_id": cls.categ_1.id}
)
self.page = self.env["document.page"].create(
{"name": "Page 1", "type": "content", "parent_id": self.categ_1.id}
cls.page = cls.env["document.page"].create(
{"name": "Page 1", "type": "content", "parent_id": cls.categ_1.id}
)

def test_document_page_group(self):
Expand Down

0 comments on commit bc8c59f

Please sign in to comment.