summaryrefslogtreecommitdiffstats
path: root/sigcore/test/TestScript.h
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2008-12-23 16:54:34 -0500
committerBen Boeckel <MathStuf@gmail.com>2008-12-23 16:54:34 -0500
commit73808809ef8a3e2448081b73a70d91cebecfffc6 (patch)
tree26d511775460f39c6ae835eca200844d8d0166d6 /sigcore/test/TestScript.h
parentc2462fdb8a60517beb67a89b55e078a2cbea30c4 (diff)
downloadsigen-73808809ef8a3e2448081b73a70d91cebecfffc6.tar.gz
sigen-73808809ef8a3e2448081b73a70d91cebecfffc6.tar.xz
sigen-73808809ef8a3e2448081b73a70d91cebecfffc6.zip
Adding Script tests and made the CMake file link only necessary things
Diffstat (limited to 'sigcore/test/TestScript.h')
-rw-r--r--sigcore/test/TestScript.h51
1 files changed, 51 insertions, 0 deletions
diff --git a/sigcore/test/TestScript.h b/sigcore/test/TestScript.h
new file mode 100644
index 00000000..8768d593
--- /dev/null
+++ b/sigcore/test/TestScript.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2008 Ben Boeckel <MathStuf@gmail.com>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef TESTSCRIPT
+#define TESTSCRIPT
+
+// Sigcore includes
+#include "../Script.h"
+
+class TestScript : public QObject
+{
+ Q_OBJECT
+ Q_PROPERTY(QString value READ value WRITE setValue)
+
+ public:
+ QString value() const;
+ void setValue(const QString& value);
+ public slots:
+ void slot1();
+ void slot2();
+ signals:
+ void signal1();
+ void signal2();
+ private:
+ bool m_foo;
+ bool m_bar;
+ QString m_value;
+ private slots:
+ void initTestCase();
+ void setInterpreter();
+ void setScript();
+ void assignment();
+ void equality();
+ void running();
+};
+
+#endif