mirror of
https://github.com/OCA/knowledge.git
synced 2025-12-19 11:52:18 -06:00
[IMP] document_page: black, isort
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
|
||||
from odoo.tests import common
|
||||
|
||||
|
||||
@@ -7,14 +6,14 @@ class TestDocumentPageHistory(common.TransactionCase):
|
||||
|
||||
def test_page_history_demo_page1(self):
|
||||
"""Test page history demo page1."""
|
||||
page = self.env.ref('document_page.demo_page1')
|
||||
page.content = 'Test content updated'
|
||||
history_document = self.env['document.page.history']
|
||||
history_pages = history_document.search([('page_id', '=', page.id)])
|
||||
page = self.env.ref("document_page.demo_page1")
|
||||
page.content = "Test content updated"
|
||||
history_document = self.env["document.page.history"]
|
||||
history_pages = history_document.search([("page_id", "=", page.id)])
|
||||
active_ids = [i.id for i in history_pages]
|
||||
|
||||
result = history_document._get_diff(active_ids[0], active_ids[0])
|
||||
self.assertEqual(result, 'There are no changes in revisions.')
|
||||
self.assertEqual(result, "There are no changes in revisions.")
|
||||
|
||||
result = history_document._get_diff(active_ids[0], active_ids[1])
|
||||
self.assertNotEqual(result, 'There are no changes in revisions.')
|
||||
self.assertNotEqual(result, "There are no changes in revisions.")
|
||||
|
||||
Reference in New Issue
Block a user