| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When I added the macro, I wasn't aware that TestCaseCollector was a
thing. TestCaseCollector loads each QML file without running the tests
(i.e. creates a QQmlComponent from the file without creating an object
from that component). Since it still executes imports, the test can
fail if types are registered or import paths added in
qmlEngineAvailable(), since it's called too late.
So, call it earlier. This should have no adverse effect on user code,
as nothing of importance to the user will be skipped, and the
documentation already details what can be expected by the time
qmlEngineAvailable() is called.
Change-Id: Ibd3a4b728bc87b90f89cc310fddf668c5879ad83
Fixes: QTBUG-74160
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|
|
|
|
|
|
|
| |
Implemented logic for filtering tests with 'case::function:tag' run syntax.
Fixes: QTBUG-71645
Change-Id: I9243636b098b4e9ccb4c74d08679bbbb9f3e8a65
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
|
|
|
|
|
|
|
| |
Fixes: QTBUG-53131
Change-Id: Ic24fe4b5db0e404b1b089a054ce76265763f2682
Reviewed-by: Robert Griebl <robert.griebl@pelagicore.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If QtQuickTest test executable was given filters that didn't match in any of the
qml files run, it exited successfully.
In combination with a Coin bug when the test function name contains a space,
this allowed failing tests to pass the CI. If the test function fails, the
repeat attempts would pass two arguments to the executable. Neither of those
hit, but that wasn't considered a problem.
Check that all of the test functions named on the command line are actually
executed during the whole run and otherwise exit with a non-zero exit code.
I assume there's no duplicates in the whole names of test functions scoped with
testcase names.
Task-number: QTBUG-68197
Change-Id: Icf7fe263945403f02920522dfd187aeb76b7cb3c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Kalle Viironen <kalle.viironen@qt.io>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
From now on we prefer nullptr instead of 0 to clarify cases where
we are assigning or testing a pointer rather than a numeric zero.
Also, replaced cases where 0 was passed as Qt::KeyboardModifiers
with Qt::NoModifier (clang-tidy replaced them with nullptr, which
waas wrong, so it was just as well to make the tests more readable
rather than to revert those lines).
Change-Id: I4735d35e4d9f42db5216862ce091429eadc6e65d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
The functions are marked Q_REQUIRED_RESULT, so they give compilation warnings
when not handling the bool return value. Failing the test early at an unexpected
event is also better behavior anyway.
Task-number: QTBUG-66559
Change-Id: I6c4db29379ec01528208c3e4ee54346b4230616c
Reviewed-by: Sami Nurmenniemi <sami.nurmenniemi@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This macro is the same as QUICK_TEST_MAIN, but takes the user's
QObject subclass as an argument, and calls pre-defined slots/invokable
functions on it, similar to how e.g. init() is called for C++ tests.
This allows e.g. context properties to be set for the QML tests.
By basing the API on invokable functions, we give ourselves the freedom
to easily add more functions in the future.
[ChangeLog][QtQuickTest] Added QUICK_TEST_MAIN_WITH_SETUP macro to
allow executing C++ before a QML test (such as registering context
properties).
Task-number: QTBUG-50064
Change-Id: Id566e388553811c220871248403d32545f8ae1eb
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It seems this is causing QTBUG-62925 and QTBUG-62926 so revert
is the best option at this point to proceed
This reverts commit 4c46dce8fd9c9dddddd1d07f56396b3eabb2efc4.
Change-Id: Ia8ea85c1ac1ada1752b29c9fbd8439f5963d46d2
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes QQuickItem::isUnderMouse returning wrong information when
moving the mouse cursor with QtQuickTest::mouseX
Also changes TestCase.mouseDrag to actually resemble more what
real life does, i.e. send mouse moves with the same localPos
if the item has already moved and update tst_drag.qml accordingly
Change-Id: I80e4ab097da90d21ba987466c1b82467755a6b56
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
|
|
2e7d4ecdc59942b484159ca827f5d5dbc8787a1b caused the regression.
To fix the regression I try accessing the signal name first
and if it is not a function try accessing the handler name.
Comes with a unit test to test both cases.
Change-Id: I3897f344df9c6219636c70259eed503d9b76f09e
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|