aboutsummaryrefslogtreecommitdiff
path: root/autotests
diff options
context:
space:
mode:
Diffstat (limited to 'autotests')
-rw-r--r--autotests/kconfigtest.cpp4
-rw-r--r--autotests/kdesktopfiletest.cpp2
-rw-r--r--autotests/kdesktopfiletest.h3
3 files changed, 6 insertions, 3 deletions
diff --git a/autotests/kconfigtest.cpp b/autotests/kconfigtest.cpp
index b915a07a..546568f8 100644
--- a/autotests/kconfigtest.cpp
+++ b/autotests/kconfigtest.cpp
@@ -748,7 +748,7 @@ void KConfigTest::testChangeGroup()
KConfigGroup sc3(&sc, "Hello");
QCOMPARE(sc3.name(), QString("Hello"));
KConfigGroup newGroup(sc3);
-#ifndef KDE_NO_DEPRECATED
+#if KCONFIGCORE_ENABLE_DEPRECATED_SINCE(5, 0)
newGroup.changeGroup("FooBar"); // deprecated!
QCOMPARE(newGroup.name(), QString("FooBar"));
QCOMPARE(sc3.name(), QString("Hello")); // unchanged
@@ -764,7 +764,7 @@ void KConfigTest::testChangeGroup()
KConfigGroup sc32(rootGroup.group("Hello"));
QCOMPARE(sc32.name(), QString("Hello"));
KConfigGroup newGroup2(sc32);
-#ifndef KDE_NO_DEPRECATED
+#if KCONFIGCORE_ENABLE_DEPRECATED_SINCE(5, 0)
newGroup2.changeGroup("FooBar"); // deprecated!
QCOMPARE(newGroup2.name(), QString("FooBar"));
QCOMPARE(sc32.name(), QString("Hello")); // unchanged
diff --git a/autotests/kdesktopfiletest.cpp b/autotests/kdesktopfiletest.cpp
index 4f8c5deb..ed13be8e 100644
--- a/autotests/kdesktopfiletest.cpp
+++ b/autotests/kdesktopfiletest.cpp
@@ -62,7 +62,7 @@ void KDesktopFileTest::testRead()
QCOMPARE(df.fileName(), QFileInfo(fileName).canonicalFilePath());
}
-#ifndef KDE_NO_DEPRECATED
+#if KCONFIGCORE_ENABLE_DEPRECATED_SINCE(5, 0)
void KDesktopFileTest::testReadDirectory()
{
QTemporaryFile file("testReadDirectoryXXXXXX.directory");
diff --git a/autotests/kdesktopfiletest.h b/autotests/kdesktopfiletest.h
index 12385f4e..621c7934 100644
--- a/autotests/kdesktopfiletest.h
+++ b/autotests/kdesktopfiletest.h
@@ -20,6 +20,7 @@
#define KDESKTOPFILETEST_H
#include <QObject>
+#include <kconfigcore_export.h>
class KDesktopFileTest : public QObject
{
@@ -27,7 +28,9 @@ class KDesktopFileTest : public QObject
private Q_SLOTS:
void initTestCase();
void testRead();
+#if KCONFIGCORE_ENABLE_DEPRECATED_SINCE(5, 0)
void testReadDirectory();
+#endif
void testReadLocalized_data();
void testReadLocalized();
void testUnsuccessfulTryExec();