aboutsummaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2015-11-30Add missing licenses.Alex Merry
2015-11-30Make sure we load translations on the main thread.Alex Merry
Because the old implementation (accidentally) worked when you put the ecm_create_qm_loader call in a different CMakeLists.txt file to the target the file was added to, some projects did this. This won't work with build-time-generated files, though, like moc files. So we (ab)use QTimer events to make the loading happen on the main thread. BUG: 346188 REVIEW: 126000
2015-11-22Overhaul the ECM build system.Alex Merry
It should now be easier to read, and more featureful. Among other tweaks, we now print a summary of dependencies and build options, and the documentation is generated with more sensible breadcrumbs and builds properly with Sphinx 1.3. REVIEW: 126075
2015-11-14Fix multiple calls to ecm_create_qm_loader.Alex Merry
Multiple ecm_create_qm_loader() with different catalog names would overwrite each other's generated files, causing the wrong catalog to be loaded at runtime for some targets. This puts the catalog name into the generated filename. Since the catalog name is the only difference between the generated files, this is sufficient to fix the runtime behaviour. REVIEW: 125999
2015-11-08Add unit test for ecm_create_qm_loader.Alex Merry
This is based on commit 6745bd7e4796560959bb67e33b7c7f86f96a5a94 (and the subsequent fix-up commits).
2015-11-08Revert "Make sure we load translations on the main thread."Alex Merry
This broke the build for projects which used ecm_create_qm_loader in unusual ways. A better approach is coming, but won't be in e-c-m 5.16. This reverts commit 009c480413910e8c1a18f4d1420f4a517ea606e6. CCBUG: 346188 CCMAIL: release-team@kde.org CCMAIL: kde-buildsystem@kde.org
2015-11-08Revert "Add license to tests."Alex Merry
This commit is dependent on 009c480413910e8c1a18f4d1420f4a517ea606e6, which is the primary commit to be reverted. This reverts commit 634a0a2d3d7ba1bec2bae846acf0faf6184f4c71.
2015-11-08Revert "Change ecm_create_po_loader test language to German."Alex Merry
This commit is dependent on 009c480413910e8c1a18f4d1420f4a517ea606e6, which is the primary commit to be reverted. This reverts commit 0496f8ae020c497b5f65234063150781d023f8ba.
2015-11-08Revert "Fix ECMPoQmToolsTest."Alex Merry
This commit is dependent on 009c480413910e8c1a18f4d1420f4a517ea606e6, which is the primary commit to be reverted. This reverts commit 39484722101730d4f1a4bccbc5467c0eb2cc0f6f.
2015-11-04Warn instead of error if ecm_install_icons finds no icons.v5.16.0-rc1Alex Merry
The V1 syntax of ecm_install_icons searched for icons by globbing files with a particular naming pattern. If there were no such icons, this used to do nothing, but silently. Commit fb7b8eea7d accidentally made this an error. More sensible would be to make it a warning. BUG: 354610 REVIEW: 125931
2015-11-03Fix ECMPoQmToolsTest.Alex Merry
LANGUAGE has higher priority than LC_ALL.
2015-11-03Change ecm_create_po_loader test language to German.Alex Merry
This is easier to distinguish from "english" in the test output than "british english".
2015-11-03Add license to tests.Alex Merry
2015-11-03Make sure we load translations on the main thread.Alex Merry
BUG: 346188 REVIEW: 123726
2015-10-20Fix ECMInstallIconsTest.Alex Merry
ECMInstallIcons now updates the theme cache if gtk-update-icon-cache is available, producing files the test hadn't been expecting.. Updating the test revealed that the old-style ecm_install_icons call only updated the hicolor cache, and not any of the other themes. REVIEW: 125631
2015-08-25add COMMON_HEADER option and multiple header functionalityv5.14.0-rc1v5.14.0Patrick Spendrin
This adds a new keyword COMMON_HEADER which generates a new header containing all other headers. Also it is possible now to have multiple dummy headers per header file. It is assumed that the first header is the existing one. REVIEW: 124847
2015-08-20correct the test name, so that we don't have a duplicate ECMGenerateHeaders testPatrick Spendrin
2015-08-19Add a license to one of the C++ test files.Alex Merry
2015-08-18Add macro to generate logging category declarations for Qt5.Alex Merry
This makes life a bit easier for developers who use the categorised logging in Qt5 in the common case - rather than creating two new files, and remembering to put in the #ifdef for the default verbosity settings in Qt 5.4, they can just add a couple of lines to their CMakeLists.txt. REVIEW: 124595
2015-06-06Fix test on OSX, no bundle expected here.v5.11.0-rc1v5.11.0David Faure
CI said: Linking C executable dummy.app/Contents/MacOS/dummy Built target dummy Could not find path to executable, perhaps it was not built: dummy REVIEW: 123969
2015-05-18Add arguments to ecm_add_tests for listing added tests.Alex Merry
This makes it convenient to make further modifications to the tests, such as setting properties on either the tests or the targets. CHANGELOG: New arguments for ecm_add_tests(). BUG: 345797 REVIEW: 123841
2015-05-16Revert "Add PROPERTIES argument to ecm_add_test and ecm_add_tests."Alex Merry
This reverts commit 0c224194ea7f12eaed32af746fc9138537f1919c. Stephen Kelly pointed out that this is probably not the best approach to the problem, and runs counter to the direction KDE's CMake code has been going (splitting functions up and using CMake built-ins where possible). I have a better solution in mind, which I'll post a review for later. CCMAIL: kde-buildsystem@kde.org CCBUG: 345797
2015-05-13Add PROPERTIES argument to ecm_add_test and ecm_add_tests.Alex Merry
This is particularly useful with ecm_add_tests, where you may want to force a suite of tests to run in serial, or alter the timeout for multiple tests at once. BUG: 345797 REVIEW: 123722
2015-05-13Add unit tests for ECMAddTests module.Alex Merry
REVIEW: 123722
2015-03-15Warn about icon filenames with leading characters.Alex Merry
Through a quirk of implementation, old-style icon filenames are accepted by the new-style ecm_install_icons function. It's too late to change it now, as that would break existing projects, but we can warn about it. REVIEW: 122941
2015-02-15Extend ecm_generate_headers macro to also support CamelCase.h headersFriedrich W. H. Kossebau
REVIEW: 122317 Thanks alexmerry and dvratil for review
2015-01-24Revert "Add SameMajorVersionWithPreleases compat option to ecm_setup_version."Alex Merry
This reverts commit 959c374c022394a116e8ceb2b1fce2df11752068. I merged and pushed the wrong branch.
2015-01-24Add SameMajorVersionWithPreleases compat option to ecm_setup_version.Alex Merry
SameMajorVersionWithPreleases is intended implement the versioning scheme followed by many KDE projects: minor releases after some high number (eg: 90) are considered to be pre-releases of the next major version, and are not compatible with the current major version. This allows alpha and beta releases to be ordered correctly by version-number-aware software like package managers (an alpha of version 2 should have a higher number than any release of version 1, but less than version 2.0). So a request for version 2.1.0 of a piece of software should not be satisfied by 2.93.4, because that is actually a pre-release of version 3. On the other hand, a request for version 2.91.0 should be satisfied by version 3.1.0. Note that prereleases are not considered unless explicitly requested, so 2.93.4 will not satisfy requests for version 3 (or version 2) of a piece of software.
2014-12-28Improve version file tests.Alex Merry
Mostly just refatoring to have less duplicated code.
2014-12-28Add deprecation warnings for old-style variables.Alex Merry
REVIEW: 121646
2014-12-28Refactor KDEInstallDirs tests.Alex Merry
REVIEW: 121646
2014-12-28Make KDEInstallDirs provide KDE_INSTALL_* variables.Alex Merry
Creating variables whose names start with CMAKE_ is a bad idea for modules distributed outside CMake itself. Since the module is called KDEInstallDirs, having a KDE_INSTALL_ prefix for the variables is clear and intuitive. Both CMAKE_INSTALL_* variables and the older KDELibs4-compatible variables are provided, unless KDE_INSTALL_DIRS_NO_DEPRECATED is set to TRUE before the module is included. Even then, the CMAKE_INSTALL_* variables provided by the GNUInstallDirs module will still be set and understood (for compatibility with that module), unless KDE_INSTALL_DIRS_NO_CMAKE_VARIABLES is set to TRUE. REVIEW: 121646
2014-12-28Add COMPATIBILITY argument to ecm_setup_version().Alex Merry
Lots of libraries will want to use SameMajorVersion to make sure searching for version 1 of a library doesn't give you version 2, for example. We may want to add another, custom compatibility mode for KDE Frameworks-style versioning, where version x.90.z to x.99.z are alpha/beta releases for version (x+1). REVIEW: 121696
2014-12-07Fix ECMSetupVersionTest/new_explicit_header_abspathAlex Merry
The #include in the main.c file did not match the generated header file name, so it was actually incorrectly including the header from another test. BUG: 341576
2014-11-07Set CMAKE_INSTALL_SYSCONFDIR to /etc when CMAKE_INSTALL_PREFIX is /usrAlex Merry
When installing to /usr, we should use /etc for configuration. Using /usr/etc does not make sense. REVIEW: 120246
2014-09-16allow qmldir to follow qt_sys_pathHarald Sitter
when running with the KDE_INSTALL_USE_QT_SYS_PATHS option allow QMLDIR in KDEInstallDirs to follow whatever is defined by qmake this change makes sure that qml plugins will end up in a default Qt path when using the super special magic flag.
2014-09-11Fix fallout from recent ECM patchesAlex Merry
KDE modules cannot assume the normal ECM modules are in the CMake module path, and CMAKE_INSTALL_IMPORTS_INSTALL_DIR / QTQUICKIMPORTSDIR was not set correctly. Also, ECMQueryQmake.cmake used a deprecated CMake command (exec_program).
2014-09-10Introduce ECMGeneratePkgConfigFileAleix Pol
A new module has been introduced to generate pkgconfig files from cmake projects. REVIEW: 119798
2014-07-18Define variable for AppStream upstream XML directoryMatthias Klumpp
REVIEW:118020
2014-07-07Define convenience variable for DATAROOTDIR/kxmlgui5.David Faure
See RR 119142 for more details.
2014-06-17Make ECM language-independent again, but make the tests use CAlex Merry
Setting the language for ECM's project() call to C had unanticipated side-effects - notably that the installed version file required the architecture to match the one used at build time. Instead, we make the tests a sub-project, setting up C as the language there (since most of the tests do use C, albeit slightly indirectly). REVIEW: 118498
2014-06-02Reorganize testsAlex Merry
Move the detailed testing of KDEInstallDirs from ExecuteKDEModules to a subdir of KDEInstallDirsTest. This is where you would expect to find it, and it also makes sure that other KDE modules are not affecting the test. This also makes the KDEInstallDirs/not_cache_variable regression test work the same way as the other tests, doing a double-configure and build. While not stricly necessary to catch the original issue, it does ensure that the problem does not appear when reconfiguring either.
2014-05-26Skip non-directory files inside the po/ directoryAurélien Gâteau
REVIEW: 118216
2014-05-15fix running ECMKDEModules testPatrick Spendrin
REVIEW:118147
2014-05-14Do not fail if vars like CMAKE_INSTALL_LIBDIR are defined as normal varsAurélien Gâteau
REVIEW: 118127
2014-05-13More complete testing of ECMPoQmToolsAurélien Gâteau
- Test calling ecm_process_po_files_as_qm() without INSTALL_DESTINATION argument - Test calling ecm_install_po_files_as_qm() with CMAKE_INSTALL_LOCALEDIR set and with LOCALE_INSTALL_DIR set REVIEW: 118114
2014-05-13Use CMAKE_INSTALL_FOODIR style variables for KDEInstallDirsAlex Merry
This matches how CMake's GNUInstallDirs does things. REVIEW: 118057
2014-05-12Check that KDEInstallDirs defines the variables it claims toAlex Merry
2014-05-04Add ECMPoQmTools moduleAurélien Gâteau
ecm_create_qm_from_po_files() was actually not very useful in practice. So that is deprecated, to be removed before ECM 1.0. Instead, the ECMPoQmTools provides several useful functions: ecm_create_qm_loader() (which already existed in ECMCreateQmFromPoFiles), ecm_process_po_files_as_qm() (which has the same signature as gettext_process_po_files() from the FindGettext module) and ecm_install_po_files_as_qm(), which is a convenience function mostly for the benefit of KDE Frameworks (although potentially useful for whatever other projects have the unusual requirement of a Gettext translation workflow but no Gettext usage in the code). NB: some clean-up to the documentation was done by Alex Merry <alex.merry@kde.org> as part of this commit. REVIEW: 117823
2014-04-25Split up module execution testsAlex Merry
Find module tests now use find_package(), and there is a version for when CMAKE_MODULE_PATH is set and a version for when ecm_use_find_modules() is used. KDE modules are also now tested. REVIEW 117658