tests: add PhysicsTestCase QML type
TestCase blocks used a "when: <condition>" pattern with an empty
placeholder function that QtQuickTest never actually recognized as a
test (function names require a "test_" prefix), so a scene that never
reached its expected state would hang the test binary forever instead
of failing.
Add a QtQuick3D.Physics.TestUtils::PhysicsTestCase type that fails with
a clear message if its goalReached condition isn't met within
timeoutSecs (30s by default), and switch every auto test to use it
instead of duplicating the timeout logic.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Pick-to: 6.12 6.11 6.8
Change-Id: I38993983d135432150f342d7286eb54214bbd42c
Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io>
| commit | 740ce88214bb9f0ae2190280626791cedcb7bf18 |
| parent | e1041b5be292f8e4deae76610ebaa73813415a1e |
| author | Jonas Karlsson <jonas.karlsson@qt.io> |
| committer | Jonas Karlsson <jonas.karlsson@qt.io> |
| commit time | Wed, 5 Aug 2026 22:16:20 +0000 |
- M tests/auto/callback/tst_callback.cpp
- M tests/auto/callback/tst_callback.qml
- M tests/auto/callback/tst_callback_report.qml
- M tests/auto/callback_create_delete_joint/tst_callback_create_delete_joints.cpp
- M tests/auto/callback_create_delete_joint/tst_callback_create_delete_joints.qml
- M tests/auto/callback_create_delete_node/tst_callback_create_delete_node.cpp
- M tests/auto/callback_create_delete_node/tst_callback_create_delete_node.qml
- M tests/auto/changescene/tst_changescene.cpp
- M tests/auto/changescene/tst_changescene.qml
- M tests/auto/character/tst_character.cpp
- M tests/auto/character/tst_character.qml
- M tests/auto/character_remove/tst_character_remove.cpp
- M tests/auto/character_remove/tst_character_remove.qml
- M tests/auto/character_resize/tst_character_resize.cpp
- M tests/auto/character_resize/tst_character_resize.qml
- M tests/auto/cooked/data/tst_cooked.qml
- M tests/auto/cooked/tst_cooked.cpp
- M tests/auto/enable_disable/tst_enable_disable.cpp
- M tests/auto/enable_disable/tst_enable_disable.qml
- M tests/auto/filtering/tst_filtering.cpp
- M tests/auto/filtering/tst_filtering.qml
- M tests/auto/geometry/tst_geometry.cpp
- M tests/auto/geometry/tst_geometry.qml
- M tests/auto/geometry_builtin/tst_geometry_builtin.cpp
- M tests/auto/geometry_builtin/tst_geometry_builtin.qml
- M tests/auto/geometry_readd/tst_geometry_readd.cpp
- M tests/auto/geometry_readd/tst_geometry_readd.qml
- M tests/auto/geometry_source/tst_geometry_source.cpp
- M tests/auto/geometry_source/tst_geometry_source.qml
- M tests/auto/geometry_update/tst_geometry_update.cpp
- M tests/auto/geometry_update/tst_geometry_update.qml
- M tests/auto/heightfield/tst_heightfield.cpp
- M tests/auto/heightfield/tst_heightfield.qml
- M tests/auto/heightfield_readd/tst_heightfield_readd.cpp
- M tests/auto/heightfield_readd/tst_heightfield_readd.qml
- M tests/auto/invalidscene/tst_invalidscene.cpp
- M tests/auto/invalidscene/tst_invalidscene.qml
- M tests/auto/joints/tst_joints.cpp
- M tests/auto/joints/tst_joints.qml
- M tests/auto/multiscene/tst_multiscene.cpp
- M tests/auto/multiscene/tst_multiscene.qml
- M tests/auto/physicsscene/data/tst_physicsscene.qml
- M tests/auto/physicsscene/tst_physicsscene.cpp
- M tests/auto/prismaticjoint/tst_prismatic_joint.cpp
- M tests/auto/prismaticjoint/tst_prismatic_joint.qml
- M tests/auto/revolutejoint/tst_revolute_joint.cpp
- M tests/auto/revolutejoint/tst_revolute_joint.qml
- M tests/auto/shared/util.h