Skip to content

Commit

Permalink
disable test for plone < 6
Browse files Browse the repository at this point in the history
  • Loading branch information
cekk committed Dec 5, 2024
1 parent 6019fc3 commit ba88efa
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/redturtle/volto/tests/test_blocks_linkintegrity.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# -*- coding: utf-8 -*-
from importlib import import_module
from plone import api
from plone.app.testing import setRoles
from plone.app.testing import TEST_USER_ID
Expand All @@ -9,6 +10,10 @@

import unittest

HAS_PLONE_6 = getattr(
import_module("Products.CMFPlone.factory"), "PLONE60MARKER", False
)


class TestBlocksLinkIntegrity(unittest.TestCase):
layer = REDTURTLE_VOLTO_FUNCTIONAL_TESTING
Expand Down Expand Up @@ -704,6 +709,10 @@ def test_count_down_countdown_text_link_integrity(self):
self.assertEqual(reference["sources"][0]["uid"], self.document.UID())
self.assertEqual(reference["target"]["uid"], self.ref.UID())

@unittest.skipIf(
not HAS_PLONE_6,
"This test is only intended to run for Plone 6 and DX site root enabled",
)
def test_linkintegrity_works_also_on_site_root(self):
self.assertEqual(self.get_references(), [])
self.portal.blocks = {
Expand Down

0 comments on commit ba88efa

Please sign in to comment.