Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Dec 9, 2024
1 parent adfa874 commit 8b447f2
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions tests/src/python/test_qgsprojectstylesettings.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Qt,
QTemporaryDir,
QTemporaryFile,
QT_VERSION
QT_VERSION,
)
from qgis.PyQt.QtGui import QColor, QColorSpace, QFont
from qgis.PyQt.QtTest import QSignalSpy
Expand Down Expand Up @@ -890,7 +890,9 @@ def testReadWrite(self):
[unitTestDataPath() + "/style1.db", unitTestDataPath() + "/style2.db"],
)

@unittest.skipIf(QT_VERSION < 0x060800, "CMYK support was not complete before Qt 6.8.0")
@unittest.skipIf(
QT_VERSION < 0x060800, "CMYK support was not complete before Qt 6.8.0"
)
def testColorSettings(self):
"""
Test ICC profile attachment
Expand Down Expand Up @@ -933,7 +935,9 @@ def testColorSettings(self):
self.assertTrue(project.isDirty())
self.assertEqual(settings.colorModel(), Qgis.ColorModel.Cmyk)
self.assertTrue(settings.colorSpace().isValid())
self.assertEqual(settings.colorSpace().primaries(), QColorSpace.Primaries.Custom)
self.assertEqual(
settings.colorSpace().primaries(), QColorSpace.Primaries.Custom
)
self.assertEqual(len(project.attachedFiles()), 2)

# save and restore
Expand All @@ -948,7 +952,9 @@ def testColorSettings(self):
settings = project.styleSettings()
self.assertEqual(settings.colorModel(), Qgis.ColorModel.Cmyk)
self.assertTrue(settings.colorSpace().isValid())
self.assertEqual(settings.colorSpace().primaries(), QColorSpace.Primaries.Custom)
self.assertEqual(
settings.colorSpace().primaries(), QColorSpace.Primaries.Custom
)
self.assertEqual(len(project.attachedFiles()), 2)

# clear color space
Expand Down

0 comments on commit 8b447f2

Please sign in to comment.