summaryrefslogtreecommitdiffstats
path: root/test cases/frameworks/4 qt/subfolder/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test cases/frameworks/4 qt/subfolder/main.cpp')
-rw-r--r--test cases/frameworks/4 qt/subfolder/main.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/test cases/frameworks/4 qt/subfolder/main.cpp b/test cases/frameworks/4 qt/subfolder/main.cpp
new file mode 100644
index 0000000..9661811
--- /dev/null
+++ b/test cases/frameworks/4 qt/subfolder/main.cpp
@@ -0,0 +1,29 @@
+#include <QImage>
+#include <QFile>
+#include <QString>
+
+int main(int argc, char **argv) {
+ #ifndef UNITY_BUILD
+ Q_INIT_RESOURCE(stuff3);
+ Q_INIT_RESOURCE(stuff4);
+ #endif
+
+ for(auto fname:{":/thing.png", ":/thing4.png"})
+ {
+ QImage img1(fname);
+ if(img1.width() != 640) {
+ return 1;
+ }
+ }
+
+ for(auto fname:{":/txt_resource.txt",":/txt_resource2.txt"})
+ {
+ QFile file(fname);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
+ return 1;
+ QString line = file.readLine();
+ if(line.compare("Hello World"))
+ return 1;
+ }
+ return 0;
+} \ No newline at end of file