Krita is a free and open source cross-platform application that offers an end-to-end solution for creating digital art files from scratch built on the KDE and Qt frameworks.
C++
Fix TestColorConversionSystem
Dmitry Kazakovd6e64013cc17
diff --git a/libs/pigment/tests/TestColorConversionSystem.cpp b/libs/pigment/tests/TestColorConversionSystem.cppindex cc67491b86..f4b9ef5451 100644--- a/libs/pigment/tests/TestColorConversionSystem.cpp+++ b/libs/pigment/tests/TestColorConversionSystem.cpp@@ -516,14 +516,16 @@ void TestColorConversionSystem::testRec2020PQConnectionPaths()QFETCH(std::vector<NodeKey>, expectedPath);auto loadExternalProfile = [](const QString &profileName, const QString &profileFileName) {- if (!KoColorSpaceRegistry::instance()->profileByName(profileName)) {+ const KoColorProfile *profile = KoColorSpaceRegistry::instance()->profileByName(profileName);+ if (!profile || profile->name() != profileName) {const QString profileFilePath = TestUtil::fetchDataFileLazy(profileFileName);KIS_ASSERT(QFile::exists(profileFilePath));{KoColorSpaceEngine *iccEngine = KoColorSpaceEngineRegistry::instance()->get("icc");KIS_ASSERT(iccEngine);- (void)iccEngine->addProfile(profileFilePath);+ const KoColorProfile *profile = iccEngine->addProfile(profileFilePath);+ KIS_ASSERT(profile);}}};