Commit 604ef6d4 authored by Oswald Buddenhagen's avatar Oswald Buddenhagen Committed by Maurice Kalinowski
Browse files

automatically put TESTDATA into RESOURCES on android/ios/winrt


QFINDTESTDATA is already prepared to find it there.

Change-Id: I467392786ce6bcfbf1bd0b6079f60c9df06834b1
Reviewed-by: default avatarTor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Reviewed-by: default avatarOliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: default avatarMaurice Kalinowski <maurice.kalinowski@theqtcompany.com>
Showing with 18 additions and 1 deletion
...@@ -55,6 +55,9 @@ QMAKE_DIR_REPLACE_SANE = PRECOMPILED_DIR OBJECTS_DIR MOC_DIR RCC_DIR UI_DIR ...@@ -55,6 +55,9 @@ QMAKE_DIR_REPLACE_SANE = PRECOMPILED_DIR OBJECTS_DIR MOC_DIR RCC_DIR UI_DIR
cross_compile: \ cross_compile: \
CONFIG += force_bootstrap CONFIG += force_bootstrap
android|ios|winrt: \
CONFIG += builtin_testdata
CONFIG += \ CONFIG += \
create_prl link_prl \ create_prl link_prl \
prepare_docs qt_docs_targets \ prepare_docs qt_docs_targets \
......
...@@ -79,7 +79,7 @@ isEmpty(BUILDS)|build_pass { ...@@ -79,7 +79,7 @@ isEmpty(BUILDS)|build_pass {
INSTALLS += target INSTALLS += target
} }
contains(INSTALLS, target) { !builtin_testdata:contains(INSTALLS, target) {
# Install testdata and helpers as well, but only if we're actually installing the test. # Install testdata and helpers as well, but only if we're actually installing the test.
# #
# Testdata is installed relative to the directory containing the testcase # Testdata is installed relative to the directory containing the testcase
...@@ -180,6 +180,20 @@ contains(INSTALLS, target) { ...@@ -180,6 +180,20 @@ contains(INSTALLS, target) {
} }
} }
builtin_testdata {
ALL_TESTDATA = $$TESTDATA $$GENERATED_TESTDATA
# RESOURCES does not support wildcards (for good reasons)
for(td, ALL_TESTDATA): \
testdata.files += $$files($$absolute_path($$td, $$_PRO_FILE_PWD_))
!isEmpty(testdata.files) {
testdata.base = $$_PRO_FILE_PWD_
RESOURCES += testdata
}
!isEmpty(TEST_HELPER_INSTALLS): \
error("This platform does not support tests which require helpers.")
}
macx-xcode:bundle:isEmpty(QMAKE_BUNDLE_EXTENSION) { macx-xcode:bundle:isEmpty(QMAKE_BUNDLE_EXTENSION) {
QMAKE_PBX_PRODUCT_TYPE = com.apple.product-type.bundle.unit-test QMAKE_PBX_PRODUCT_TYPE = com.apple.product-type.bundle.unit-test
QMAKE_PBX_BUNDLE_TYPE = wrapper.cfbundle QMAKE_PBX_BUNDLE_TYPE = wrapper.cfbundle
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment