summaryrefslogtreecommitdiffstats
path: root/Tests/QtAutogen/ObjectLibrary/a
diff options
context:
space:
mode:
authorSebastian Holtermann <sebholt@xwmw.org>2017-12-08 19:01:48 (GMT)
committerSebastian Holtermann <sebholt@xwmw.org>2017-12-13 12:50:18 (GMT)
commitb8ef28ae1f442144f55e23b8defffe01aa350c44 (patch)
tree7dfb2158fbd85e80f50e31611acceefcd3350a0a /Tests/QtAutogen/ObjectLibrary/a
parent0b6ad59ea6b74379f4aefb42c2402355c393c656 (diff)
downloadCMake-b8ef28ae1f442144f55e23b8defffe01aa350c44.zip
CMake-b8ef28ae1f442144f55e23b8defffe01aa350c44.tar.gz
CMake-b8ef28ae1f442144f55e23b8defffe01aa350c44.tar.bz2
Autogen: Tests: Separate ObjectLibrary test
Diffstat (limited to 'Tests/QtAutogen/ObjectLibrary/a')
-rw-r--r--Tests/QtAutogen/ObjectLibrary/a/CMakeLists.txt2
-rw-r--r--Tests/QtAutogen/ObjectLibrary/a/classa.cpp7
-rw-r--r--Tests/QtAutogen/ObjectLibrary/a/classa.h23
3 files changed, 32 insertions, 0 deletions
diff --git a/Tests/QtAutogen/ObjectLibrary/a/CMakeLists.txt b/Tests/QtAutogen/ObjectLibrary/a/CMakeLists.txt
new file mode 100644
index 0000000..fe76ac3
--- /dev/null
+++ b/Tests/QtAutogen/ObjectLibrary/a/CMakeLists.txt
@@ -0,0 +1,2 @@
+add_library(a OBJECT classa.cpp)
+target_compile_features(a PRIVATE ${QT_COMPILE_FEATURES})
diff --git a/Tests/QtAutogen/ObjectLibrary/a/classa.cpp b/Tests/QtAutogen/ObjectLibrary/a/classa.cpp
new file mode 100644
index 0000000..4f08fda
--- /dev/null
+++ b/Tests/QtAutogen/ObjectLibrary/a/classa.cpp
@@ -0,0 +1,7 @@
+#include "classa.h"
+#include <QDebug>
+
+void ClassA::slotDoSomething()
+{
+ qDebug() << m_member;
+}
diff --git a/Tests/QtAutogen/ObjectLibrary/a/classa.h b/Tests/QtAutogen/ObjectLibrary/a/classa.h
new file mode 100644
index 0000000..fa5fed9
--- /dev/null
+++ b/Tests/QtAutogen/ObjectLibrary/a/classa.h
@@ -0,0 +1,23 @@
+#ifndef CLASSA_H
+#define CLASSA_H
+
+#include <QObject>
+#include <QString>
+
+class ClassA : public QObject
+{
+ Q_OBJECT
+public:
+ ClassA()
+ : m_member("Hello A")
+ {
+ }
+
+public slots:
+ void slotDoSomething();
+
+private:
+ QString m_member;
+};
+
+#endif