diff --git a/tests/ui/modules/Common/Dialog/ConfirmDialog.spec.qml b/tests/ui/modules/Common/Dialog/ConfirmDialog.spec.qml index d4019e5e0..6f640c684 100644 --- a/tests/ui/modules/Common/Dialog/ConfirmDialog.spec.qml +++ b/tests/ui/modules/Common/Dialog/ConfirmDialog.spec.qml @@ -6,25 +6,6 @@ import QtTest 1.1 TestCase { id: testCase - name: 'ConfirmDialogTests' - - Component { - id: builder - - Item { - ConfirmDialog { - id: confirmDialog - } - - SignalSpy { - id: spy - - signalName: 'exitStatus' - target: confirmDialog - } - } - } - function buildConfirmDialog () { var container = builder.createObject(testCase) verify(container) @@ -35,6 +16,8 @@ TestCase { return container } + // ----------------------------------------------------------------- + function test_exitStatusViaButtons_data () { return [ { button: 0, expectedStatus: 0 }, @@ -52,6 +35,8 @@ TestCase { compare(spy.signalArguments[0][0], data.expectedStatus) } + // ----------------------------------------------------------------- + function test_exitStatusViaClose () { var container = buildConfirmDialog() var dialog = container.data[0] @@ -61,4 +46,23 @@ TestCase { spy.wait(100) compare(spy.signalArguments[0][0], 0) } + + // ----------------------------------------------------------------- + + Component { + id: builder + + Item { + ConfirmDialog { + id: confirmDialog + } + + SignalSpy { + id: spy + + signalName: 'exitStatus' + target: confirmDialog + } + } + } } diff --git a/tests/ui/modules/Common/Form/ExclusiveButtons.spec.qml b/tests/ui/modules/Common/Form/ExclusiveButtons.spec.qml index 9691e2ae8..ace394f50 100644 --- a/tests/ui/modules/Common/Form/ExclusiveButtons.spec.qml +++ b/tests/ui/modules/Common/Form/ExclusiveButtons.spec.qml @@ -6,6 +6,14 @@ import QtTest 1.1 Item { id: root + function buildExclusiveButtons (defaultSelectedButton) { + var container = builder.createObject(root) + testCase.verify(container) + + container.data[0].selectedButton = defaultSelectedButton + return container + } + // Avoid `Test 'XXX' has invalid size QSize(0, 0), resizing.` warning. height: 100 width: 300 @@ -35,17 +43,10 @@ Item { } } - function buildExclusiveButtons (defaultSelectedButton) { - var container = builder.createObject(root) - testCase.verify(container) - container.data[0].selectedButton = defaultSelectedButton - return container - } + // ----------------------------------------------------------------- TestCase { id: testCase - - name: 'ExclusiveButtonsTests' when: windowShown function test_signals_data () { diff --git a/tests/ui/modules/Common/InvertedMouseArea.spec.qml b/tests/ui/modules/Common/InvertedMouseArea.spec.qml index 7f9b5025e..530d0cc06 100644 --- a/tests/ui/modules/Common/InvertedMouseArea.spec.qml +++ b/tests/ui/modules/Common/InvertedMouseArea.spec.qml @@ -88,7 +88,7 @@ Rectangle { { x: item.x + item.width - 1, y: item.y }, { x: item.x, y: item.y + item.height - 1}, { x: item.x + item.width - 1, y: item.y + item.height - 1 }, - { } // item center. + { } // (x, y) = item center. ] } diff --git a/tests/ui/scripts/Utils/utils.spec.qml b/tests/ui/scripts/Utils/utils.spec.qml index faffd6e16..6b763e7c9 100644 --- a/tests/ui/scripts/Utils/utils.spec.qml +++ b/tests/ui/scripts/Utils/utils.spec.qml @@ -10,8 +10,6 @@ import './utils.js' as Utils TestCase { id: testCase - name: 'UtilsTests' - // Test only if a confirm dialog can be opened. // The other tests are launched by `ConfirmDialog.spec.qml`. function test_openConfirmDialog () {