diff options
author | Alexey Edelev <alexey.edelev@qt.io> | 2022-02-09 16:24:24 +0100 |
---|---|---|
committer | Alexey Edelev <alexey.edelev@qt.io> | 2022-02-11 21:54:44 +0100 |
commit | fdf5d11ff6f3f5034d7d7f7664f4cc76deb26ef5 (patch) | |
tree | 22e1c4b93f718930b8c40c2ab68f1b2bc790f97e /tests/auto/gui/text/qfont | |
parent | 52492ff7209d2c91cbd0d549282459b58fbf3b0f (diff) |
CMake: Add BUILTIN_TESTDATA option to qt_internal_add_test
Multiple tests use qt_internal_add_resource that copies the
functionality that is already implemented inside the
qt_internal_add_test function. Simplify these test by replacing
the qt_internal_add_resource call with the new BUILTIN_TESTDATA
option.
Change-Id: I18475b817d6f87264f0de53817d6c26c5ccab4e2
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'tests/auto/gui/text/qfont')
-rw-r--r-- | tests/auto/gui/text/qfont/CMakeLists.txt | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/tests/auto/gui/text/qfont/CMakeLists.txt b/tests/auto/gui/text/qfont/CMakeLists.txt index 6e0583bc30..048416495b 100644 --- a/tests/auto/gui/text/qfont/CMakeLists.txt +++ b/tests/auto/gui/text/qfont/CMakeLists.txt @@ -4,6 +4,12 @@ ## tst_qfont Test: ##################################################################### +# Resources: +set(testfont_resource_files + "datastream.515" + "weirdfont.otf" +) + qt_internal_add_test(tst_qfont SOURCES tst_qfont.cpp @@ -12,22 +18,10 @@ qt_internal_add_test(tst_qfont Qt::Gui Qt::GuiPrivate Qt::TestPrivate + TESTDATA ${testfont_resource_files} + BUILTIN_TESTDATA ) -# Resources: -set(testfont_resource_files - "datastream.515" - "weirdfont.otf" -) - -qt_internal_add_resource(tst_qfont "testfont" - PREFIX - "/" - FILES - ${testfont_resource_files} -) - - ## Scopes: ##################################################################### |