aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qmltest-blacklist
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-06-01 10:03:32 +0200
committerLiang Qi <liang.qi@qt.io>2016-06-02 15:22:21 +0000
commit38b11b7b52b418629ff2d245dad70edf20eb520c (patch)
tree7808d6550a6281b311b2facf05d854784e8a2941 /tests/auto/qmltest-blacklist
parent32e0c5f96dac3f8afe187259929dd87012e1a464 (diff)
Removed insignificant of qmltest again
Blacklisted or skipped broken and unstable test functions. Some are moved to tests/auto/qmltest-blacklist folder. Task-number: QTBUG-33723 Task-number: QTBUG-38290 Task-number: QTBUG-53778 Task-number: QTBUG-53779 Task-number: QTBUG-53780 Task-number: QTBUG-53781 Task-number: QTBUG-53782 Task-number: QTBUG-53785 Task-number: QTBUG-53793 Change-Id: I35594d0d054f4f5719f6549536a1fc5bd7e2518f Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'tests/auto/qmltest-blacklist')
-rw-r--r--tests/auto/qmltest-blacklist/animators/Box.qml62
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_behavior.qml67
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_mixed.qml171
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_mixedparallel.qml66
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_mixedsequential.qml66
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_multiwindow.qml95
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_nested.qml84
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_on.qml71
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_opacity.qml67
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_parallel.qml66
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_restart.qml77
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_rotation.qml65
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_scale.qml66
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_sequential.qml66
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_targetdestroyed.qml77
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_transformorigin.qml152
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_transition.qml83
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_x.qml68
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_y.qml68
-rw-r--r--tests/auto/qmltest-blacklist/animators/tst_zeroduration.qml35
-rw-r--r--tests/auto/qmltest-blacklist/item/tst_layerInPositioner.qml199
-rw-r--r--tests/auto/qmltest-blacklist/itemgrabber/tst_itemgrabber.qml152
22 files changed, 1923 insertions, 0 deletions
diff --git a/tests/auto/qmltest-blacklist/animators/Box.qml b/tests/auto/qmltest-blacklist/animators/Box.qml
new file mode 100644
index 0000000000..46218bed3f
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/Box.qml
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+
+Rectangle {
+ id: box
+ gradient: Gradient {
+ GradientStop { position: 0.1; color: "red" }
+ GradientStop { position: 0.9; color: "blue" }
+ }
+ width: 100
+ height: 100
+ anchors.centerIn: parent
+ antialiasing: true
+
+ property int rotationChangeCounter: 0
+ onRotationChanged: ++rotationChangeCounter;
+
+ property int scaleChangeCounter: 0
+ onScaleChanged: ++scaleChangeCounter;
+
+ property int opacityChangeCounter: 0
+ onOpacityChanged: ++opacityChangeCounter
+
+ property int xChangeCounter: 0;
+ onXChanged: ++xChangeCounter;
+
+ property int yChangeCounter: 0;
+ onYChanged: ++yChangeCounter;
+
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_behavior.qml b/tests/auto/qmltest-blacklist/animators/tst_behavior.qml
new file mode 100644
index 0000000000..91145909d0
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_behavior.qml
@@ -0,0 +1,67 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-behavior"
+ when: box.scale == 2
+ function test_endresult() {
+ compare(box.scaleChangeCounter, 1);
+ compare(box.scale, 2);
+ var image = grabImage(root);
+
+ verify(image.pixel(0, 0) == Qt.rgba(1, 0, 0));
+ verify(image.pixel(199, 199) == Qt.rgba(0, 0, 1));
+ }
+ }
+
+ Box {
+ id: box
+ Behavior on scale { ScaleAnimator { id: animation; duration: 100; } }
+ }
+
+ Timer {
+ interval: 100;
+ repeat: false
+ running: true
+ onTriggered: box.scale = 2
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_mixed.qml b/tests/auto/qmltest-blacklist/animators/tst_mixed.qml
new file mode 100644
index 0000000000..a738baba25
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_mixed.qml
@@ -0,0 +1,171 @@
+/****************************************************************************
+**
+** Copyright (C) 2014 Jolla Ltd, author: <gunnar.sletta@jollamobile.com>
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-mixed"
+ when: !rootAnimation.running
+ function test_endresult() {
+ compare(box.rootStart, 2);
+ compare(box.rootEnd, 2);
+
+ compare(parallelWithOneSequential.before, 4);
+ compare(parallelWithOneSequential.scaleUpdates, 4);
+
+ compare(parallelWithTwoSequentialNormalEndsLast.beforeAnimator, 4);
+ compare(parallelWithTwoSequentialNormalEndsLast.scaleUpdates, 4);
+ compare(parallelWithTwoSequentialNormalEndsLast.afterAnimator, 4);
+ compare(parallelWithTwoSequentialNormalEndsLast.beforePause, 4);
+ compare(parallelWithTwoSequentialNormalEndsLast.afterPause, 4);
+
+ compare(parallelWithTwoSequentialNormalEndsFirst.beforeAnimator, 4);
+ compare(parallelWithTwoSequentialNormalEndsFirst.scaleUpdates, 4);
+ compare(parallelWithTwoSequentialNormalEndsFirst.afterAnimator, 4);
+ compare(parallelWithTwoSequentialNormalEndsFirst.beforePause, 4);
+ compare(parallelWithTwoSequentialNormalEndsFirst.afterPause, 4);
+
+ }
+ }
+
+ Box {
+ id: box
+
+ property int rootStart : 0
+ property int rootEnd : 0;
+
+ SequentialAnimation {
+ id: rootAnimation
+
+ running: true
+ loops: 2
+
+ ScriptAction { script: box.rootStart++; }
+
+ ParallelAnimation {
+ id: parallelWithOneSequential
+ property int before : 0;
+ property int scaleUpdates : 0;
+ loops: 2
+ SequentialAnimation {
+ ScriptAction { script: {
+ parallelWithOneSequential.before++;
+ box.scale = 1;
+ box.scaleChangeCounter = 0;
+ }
+ }
+ ScaleAnimator { target: box; from: 1; to: 2; duration: 100; }
+ ScriptAction { script: {
+ parallelWithOneSequential.scaleUpdates += box.scaleChangeCounter;
+ }
+ }
+ }
+ }
+
+ ParallelAnimation {
+ id: parallelWithTwoSequentialNormalEndsLast
+ property int beforeAnimator : 0;
+ property int scaleUpdates : 0;
+ property int afterAnimator : 0;
+ property int beforePause : 0;
+ property int afterPause : 0;
+ loops: 2
+ SequentialAnimation {
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsLast.beforeAnimator++;
+ box.scale = 1;
+ box.scaleChangeCounter = 0;
+ }
+ }
+ ScaleAnimator { target: box; from: 1; to: 2; duration: 100; }
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsLast.scaleUpdates += box.scaleChangeCounter;
+ parallelWithTwoSequentialNormalEndsLast.afterAnimator++;
+ }
+ }
+ }
+ SequentialAnimation {
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsLast.beforePause++
+ }
+ }
+ PauseAnimation { duration: 200 }
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsLast.afterPause++
+ }
+ }
+ }
+ }
+
+ ParallelAnimation {
+ id: parallelWithTwoSequentialNormalEndsFirst
+ property int beforeAnimator : 0;
+ property int scaleUpdates : 0;
+ property int afterAnimator : 0;
+ property int beforePause : 0;
+ property int afterPause : 0;
+ loops: 2
+ SequentialAnimation {
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsFirst.beforeAnimator++;
+ box.scale = 1;
+ box.scaleChangeCounter = 0;
+ }
+ }
+ ScaleAnimator { target: box; from: 1; to: 2; duration: 200; }
+ ScriptAction { script: {
+ parallelWithTwoSequentialNormalEndsFirst.scaleUpdates += box.scaleChangeCounter;
+ parallelWithTwoSequentialNormalEndsFirst.afterAnimator++;
+ }
+ }
+ }
+ SequentialAnimation {
+ ScriptAction { script: parallelWithTwoSequentialNormalEndsFirst.beforePause++ }
+ PauseAnimation { duration: 100 }
+ ScriptAction { script: parallelWithTwoSequentialNormalEndsFirst.afterPause++ }
+ }
+ }
+
+ ScriptAction { script: box.rootEnd++; }
+ }
+
+ }
+
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_mixedparallel.qml b/tests/auto/qmltest-blacklist/animators/tst_mixedparallel.qml
new file mode 100644
index 0000000000..9d36fd10dc
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_mixedparallel.qml
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-mixedparallel"
+ when: !animation.running
+ function test_endresult() {
+ compare(box.rotationChangeCounter, 1);
+ compare(box.scale, 2);
+ compare(box.rotation, 180);
+ var image = grabImage(root);
+ verify(image.pixel(0, 0) == Qt.rgba(0, 0, 1));
+ verify(image.pixel(199, 199) == Qt.rgba(1, 0, 0));
+ }
+ }
+
+ Box {
+ id: box
+ ParallelAnimation {
+ id: animation
+ NumberAnimation { target: box; property: "scale"; from: 1; to: 2.0; duration: 100; }
+ RotationAnimator { target: box; from: 0; to: 180; duration: 100; }
+ running: true
+ loops: 1;
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_mixedsequential.qml b/tests/auto/qmltest-blacklist/animators/tst_mixedsequential.qml
new file mode 100644
index 0000000000..0d58fc788e
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_mixedsequential.qml
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-mixedsequential"
+ when: !animation.running
+ function test_endresult() {
+ compare(box.rotationChangeCounter, 1);
+ compare(box.scale, 2);
+ compare(box.rotation, 180);
+ var image = grabImage(root);
+ verify(image.pixel(0, 0) == Qt.rgba(0, 0, 1));
+ verify(image.pixel(199, 199) == Qt.rgba(1, 0, 0));
+ }
+ }
+
+ Box {
+ id: box
+ ParallelAnimation {
+ id: animation
+ NumberAnimation { target: box; property: "scale"; from: 1; to: 2.0; duration: 100; }
+ RotationAnimator { target: box; from: 0; to: 180; duration: 100; }
+ running: true
+ loops: 1;
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_multiwindow.qml b/tests/auto/qmltest-blacklist/animators/tst_multiwindow.qml
new file mode 100644
index 0000000000..9a817993fe
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_multiwindow.qml
@@ -0,0 +1,95 @@
+/****************************************************************************
+**
+** Copyright (C) 2014 Jolla Ltd, author: <gunnar.sletta@jollamobile.com>
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+import QtQuick.Window 2.0
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-mixed"
+ when: countdown == 0
+ function test_endresult() {
+ verify(true, "Just making sure we didn't crash");
+ }
+ }
+
+ property int countdown: 5;
+
+ Window {
+ id: window
+
+ width: 100
+ height: 100
+
+ ShaderEffect {
+ width: 50
+ height: 50
+
+ property real t;
+ UniformAnimator on t { from: 0; to: 1; duration: 1000; loops: Animation.Infinite }
+ RotationAnimator on rotation { from: 0; to: 360; duration: 1000; loops: Animation.Infinite }
+ ScaleAnimator on scale { from: 0.5; to: 1.5; duration: 1000; loops: Animation.Infinite }
+ XAnimator on x { from: 0; to: 50; duration: 1000; loops: Animation.Infinite }
+ YAnimator on y { from: 0; to: 50; duration: 1000; loops: Animation.Infinite }
+ OpacityAnimator on opacity { from: 1; to: 0.5; duration: 1000; loops: Animation.Infinite }
+
+ fragmentShader: "
+ uniform lowp float t;
+ uniform lowp float qt_Opacity;
+ varying highp vec2 qt_TexCoord0;
+ void main() {
+ gl_FragColor = vec4(qt_TexCoord0, t, 1) * qt_Opacity;
+ }
+ "
+ }
+
+ visible: true
+ }
+
+ Timer {
+ interval: 250
+ running: true
+ repeat: true
+ onTriggered: {
+ if (window.visible)
+ --countdown
+ window.visible = !window.visible;
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_nested.qml b/tests/auto/qmltest-blacklist/animators/tst_nested.qml
new file mode 100644
index 0000000000..85f5d5a922
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_nested.qml
@@ -0,0 +1,84 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-nested"
+ when: !animation.running
+ function test_endresult() {
+ compare(box.before, 2);
+ compare(box.after, 2);
+ }
+ }
+
+ Box {
+ id: box
+
+ anchors.centerIn: undefined
+
+ property int before: 0;
+ property int after: 0;
+
+ SequentialAnimation {
+ id: animation;
+ ScriptAction { script: box.before++; }
+ ParallelAnimation {
+ ScaleAnimator { target: box; from: 2.0; to: 1; duration: 100; }
+ OpacityAnimator { target: box; from: 0; to: 1; duration: 100; }
+ }
+ PauseAnimation { duration: 100 }
+ SequentialAnimation {
+ ParallelAnimation {
+ XAnimator { target: box; from: 0; to: 100; duration: 100 }
+ RotationAnimator { target: box; from: 0; to: 90; duration: 100 }
+ }
+ ParallelAnimation {
+ XAnimator { target: box; from: 100; to: 0; duration: 100 }
+ RotationAnimator { target: box; from: 90; to: 0; duration: 100 }
+ }
+ }
+ ScriptAction { script: box.after++; }
+ running: true
+ loops: 2
+ }
+ }
+
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_on.qml b/tests/auto/qmltest-blacklist/animators/tst_on.qml
new file mode 100644
index 0000000000..3775350ae5
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_on.qml
@@ -0,0 +1,71 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-on"
+ when: !animx.running && !animy.running
+ && !anims.running && !animr.running
+ && !animo.running;
+ function test_endresult() {
+ tryCompare(box, 'xChangeCounter', 1);
+ compare(box.yChangeCounter, 1);
+ compare(box.scaleChangeCounter, 1);
+ compare(box.rotationChangeCounter, 1);
+ compare(box.opacityChangeCounter, 1);
+ compare(box.x, 100);
+ compare(box.y, 100);
+ compare(box.scale, 2);
+ compare(box.rotation, 180);
+ compare(box.opacity, 0.5);
+ }
+ }
+
+ Box {
+ id: box
+ anchors.centerIn: undefined
+ XAnimator on x { id: animx; from: 0; to: 100; duration: 100 }
+ YAnimator on y { id: animy; from: 0; to: 100; duration: 100 }
+ ScaleAnimator on scale { id: anims; from: 1; to: 2; duration: 100 }
+ RotationAnimator on rotation { id: animr ; from: 0; to: 180; duration: 100 }
+ OpacityAnimator on opacity { id: animo; from: 1; to: 0.5; duration: 100 }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_opacity.qml b/tests/auto/qmltest-blacklist/animators/tst_opacity.qml
new file mode 100644
index 0000000000..72b2c61012
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_opacity.qml
@@ -0,0 +1,67 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-opacity"
+ when: box.opacity == 0.5
+ function test_endresult() {
+ compare(box.opacityChangeCounter, 1);
+ var image = grabImage(root);
+ compare(image.red(50, 50), 255);
+ verify(image.green(50, 50) > 0);
+ verify(image.blue(50, 50) > 0);
+ }
+ }
+
+ Box {
+ id: box
+
+ OpacityAnimator {
+ id: animation
+ target: box
+ from: 1;
+ to: 0.5
+ duration: 100
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_parallel.qml b/tests/auto/qmltest-blacklist/animators/tst_parallel.qml
new file mode 100644
index 0000000000..f25bae18d5
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_parallel.qml
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-parallel"
+ when: !animation.running
+ function test_endresult() {
+ compare(box.rotationChangeCounter, 1);
+ compare(box.scaleChangeCounter, 1);
+ compare(box.scale, 2);
+ compare(box.rotation, 180);
+ var image = grabImage(root);
+ verify(image.pixel(0, 0) == Qt.rgba(0, 0, 1));
+ verify(image.pixel(199, 199) == Qt.rgba(1, 0, 0));
+ }
+ }
+
+ Box {
+ id: box
+ ParallelAnimation {
+ id: animation
+ ScaleAnimator { target: box; from: 1; to: 2.0; duration: 100; }
+ RotationAnimator { target: box; from: 0; to: 180; duration: 100; }
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_restart.qml b/tests/auto/qmltest-blacklist/animators/tst_restart.qml
new file mode 100644
index 0000000000..e029ca2059
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_restart.qml
@@ -0,0 +1,77 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ property int restartCount: 5;
+
+ TestCase {
+ id: testcase
+ name: "animators-restart"
+ when: root.restartCount == 0 && animation.running == false;
+ function test_endresult() {
+ compare(box.scale, 2);
+ }
+ }
+
+ Box {
+ id: box
+
+ ScaleAnimator {
+ id: animation
+ target: box;
+ from: 1;
+ to: 2.0;
+ duration: 100;
+ loops: 1
+ running: false;
+ }
+
+ Timer {
+ id: timer;
+ interval: 500
+ running: true
+ repeat: true
+ onTriggered: {
+ animation.running = true;
+ --root.restartCount;
+ }
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_rotation.qml b/tests/auto/qmltest-blacklist/animators/tst_rotation.qml
new file mode 100644
index 0000000000..a91af92ab1
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_rotation.qml
@@ -0,0 +1,65 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-rotation"
+ when: box.rotation == 180
+ function test_endresult() {
+ compare(box.rotationChangeCounter, 1);
+ var image = grabImage(root);
+ verify(image.pixel(50, 50) == Qt.rgba(0, 0, 1));
+ }
+ }
+
+ Box {
+ id: box
+ RotationAnimator {
+ id: animation
+ target: box
+ from: 0;
+ to: 180
+ duration: 100
+ easing.type: Easing.InOutBack
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_scale.qml b/tests/auto/qmltest-blacklist/animators/tst_scale.qml
new file mode 100644
index 0000000000..402468079a
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_scale.qml
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-scale"
+ when: box.scale == 2;
+ function test_endresult() {
+ compare(box.scaleChangeCounter, 1);
+ var image = grabImage(root);
+ verify(image.pixel(0, 0) == Qt.rgba(1, 0, 0));
+ }
+ }
+
+ Box {
+ id: box
+
+ ScaleAnimator {
+ id: animation
+ target: box
+ from: 1;
+ to: 2.0
+ duration: 100
+ easing.type: Easing.InOutCubic
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_sequential.qml b/tests/auto/qmltest-blacklist/animators/tst_sequential.qml
new file mode 100644
index 0000000000..f021bbeb7a
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_sequential.qml
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-parallel"
+ when: !animation.running
+ function test_endresult() {
+ compare(box.rotationChangeCounter, 1);
+ compare(box.scaleChangeCounter, 1);
+ compare(box.scale, 2);
+ compare(box.rotation, 180);
+ var image = grabImage(root);
+ compare(image.pixel(0, 0), Qt.rgba(0, 0, 1, 1));
+ compare(image.pixel(199, 199), Qt.rgba(1, 0, 0, 1));
+ }
+ }
+
+ Box {
+ id: box
+ SequentialAnimation {
+ id: animation
+ ScaleAnimator { target: box; from: 1; to: 2.0; duration: 100; }
+ RotationAnimator { target: box; from: 0; to: 180; duration: 100; }
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_targetdestroyed.qml b/tests/auto/qmltest-blacklist/animators/tst_targetdestroyed.qml
new file mode 100644
index 0000000000..bf9efd2162
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_targetdestroyed.qml
@@ -0,0 +1,77 @@
+/****************************************************************************
+**
+** Copyright (C) 2014 Gunnar Sletta <gunnar@sletta.org>
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-targetdestroyed"
+ when: false
+ function test_endresult() {
+ verify(true, "Got here :)");
+ }
+ }
+
+ Rectangle {
+ id: box
+ width: 10
+ height: 10
+ color: "steelblue"
+ }
+
+ YAnimator {
+ id: anim
+ target: box
+ from: 0;
+ to: 100
+ duration: 100
+ loops: Animation.Infinite
+ running: true
+ }
+
+ SequentialAnimation {
+ running: true
+ PauseAnimation { duration: 150 }
+ ScriptAction { script: box.destroy(); }
+ PauseAnimation { duration: 50 }
+ ScriptAction { script: anim.destroy(); }
+ PauseAnimation { duration: 50 }
+ ScriptAction { script: testcase.when = true }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_transformorigin.qml b/tests/auto/qmltest-blacklist/animators/tst_transformorigin.qml
new file mode 100644
index 0000000000..eed93b9843
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_transformorigin.qml
@@ -0,0 +1,152 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 300
+ height: 300
+
+ Timer {
+ id: timer;
+ running: testCase.windowShown
+ interval: 1000
+ repeat: false
+ onTriggered: triggered = true;
+ property bool triggered: false;
+ }
+
+ TestCase {
+ id: testCase
+ name: "animators-transformorigin"
+ when: timer.triggered
+ function test_endresult() {
+
+ var image = grabImage(root);
+
+ var white = Qt.rgba(1, 1, 1);
+ var blue = Qt.rgba(0, 0, 1);
+
+
+ // topleft
+ verify(image.pixel(40, 40) == white);
+ verify(image.pixel(60, 40) == white);
+ verify(image.pixel(40, 60) == white);
+ verify(image.pixel(60, 60) == blue);
+
+ // top
+ verify(image.pixel(140, 40) == white);
+ verify(image.pixel(160, 40) == white);
+ verify(image.pixel(140, 60) == blue);
+ verify(image.pixel(160, 60) == blue);
+
+ // topright
+ verify(image.pixel(240, 40) == white);
+ verify(image.pixel(260, 40) == white);
+ verify(image.pixel(240, 60) == blue);
+ verify(image.pixel(260, 60) == white);
+
+
+ // left
+ verify(image.pixel(40, 140) == white);
+ verify(image.pixel(60, 140) == blue);
+ verify(image.pixel(40, 160) == white);
+ verify(image.pixel(60, 160) == blue);
+
+ // center
+ verify(image.pixel(140, 140) == blue);
+ verify(image.pixel(160, 140) == blue);
+ verify(image.pixel(140, 160) == blue);
+ verify(image.pixel(160, 160) == blue);
+
+ // right
+ verify(image.pixel(240, 140) == blue);
+ verify(image.pixel(260, 140) == white);
+ verify(image.pixel(240, 160) == blue);
+ verify(image.pixel(260, 160) == white);
+
+
+ // bottomleft
+ verify(image.pixel(40, 240) == white);
+ verify(image.pixel(60, 240) == blue);
+ verify(image.pixel(40, 260) == white);
+ verify(image.pixel(60, 260) == white);
+
+ // bottom
+ verify(image.pixel(140, 240) == blue);
+ verify(image.pixel(160, 240) == blue);
+ verify(image.pixel(140, 260) == white);
+ verify(image.pixel(160, 260) == white);
+
+ // bottomright
+ verify(image.pixel(240, 240) == blue);
+ verify(image.pixel(260, 240) == white);
+ verify(image.pixel(240, 260) == white);
+ verify(image.pixel(260, 260) == white);
+
+ }
+ }
+
+ property var origins: [Item.TopLeft, Item.Top, Item.TopRight,
+ Item.Left, Item.Center, Item.Right,
+ Item.BottomLeft, Item.Bottom, Item.BottomRight];
+
+ Grid {
+ anchors.fill: parent
+ rows: 3
+ columns: 3
+
+ Repeater {
+ model: 9
+ Item {
+ width: 100
+ height: 100
+ Rectangle {
+ id: box
+ color: "blue"
+ anchors.centerIn: parent
+ width: 10
+ height: 10
+ antialiasing: true;
+
+ transformOrigin: root.origins[index];
+
+ ScaleAnimator { target: box; from: 1; to: 5.5; duration: 100; running: true; }
+ }
+ }
+ }
+ }
+
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_transition.qml b/tests/auto/qmltest-blacklist/animators/tst_transition.qml
new file mode 100644
index 0000000000..b02238ef23
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_transition.qml
@@ -0,0 +1,83 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testcase
+ name: "animators-transition"
+ when: box.scale == 2
+ function test_endresult() {
+ compare(box.scaleChangeCounter, 1);
+ compare(box.scale, 2);
+ var image = grabImage(root);
+ verify(image.pixel(0, 0) == Qt.rgba(1, 0, 0));
+ verify(image.pixel(199, 199) == Qt.rgba(0, 0, 1));
+ }
+ }
+
+ states: [
+ State {
+ name: "one"
+ PropertyChanges { target: box; scale: 1 }
+ },
+ State {
+ name: "two"
+ PropertyChanges { target: box; scale: 2 }
+ }
+ ]
+ state: "one"
+
+ transitions: [
+ Transition {
+ ScaleAnimator { duration: 100; }
+ }
+ ]
+
+ Box {
+ id: box
+ }
+
+ Timer {
+ interval: 100;
+ repeat: false
+ running: true
+ onTriggered: root.state = "two"
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_x.qml b/tests/auto/qmltest-blacklist/animators/tst_x.qml
new file mode 100644
index 0000000000..c462ee87d0
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_x.qml
@@ -0,0 +1,68 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-x"
+ when: box.x == 100
+ function test_endresult() {
+ compare(box.xChangeCounter, 1);
+ var image = grabImage(root);
+ verify(image.pixel(100, 0) == Qt.rgba(1, 0, 0));
+ verify(image.pixel(99, 0) == Qt.rgba(1, 1, 1)); // outside on the left
+ }
+ }
+
+ Box {
+ id: box
+
+ anchors.centerIn: undefined
+
+ XAnimator {
+ id: animation
+ target: box
+ from: 0;
+ to: 100
+ duration: 100
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_y.qml b/tests/auto/qmltest-blacklist/animators/tst_y.qml
new file mode 100644
index 0000000000..04487baee0
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_y.qml
@@ -0,0 +1,68 @@
+/****************************************************************************
+**
+** Copyright (C) 2015 The Qt Company Ltd.
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-y"
+ when: box.y == 100
+ function test_endresult() {
+ compare(box.yChangeCounter, 1);
+ var image = grabImage(root);
+ verify(image.pixel(0, 100) == Qt.rgba(1, 0, 0));
+ verify(image.pixel(0, 99) == Qt.rgba(1, 1, 1)); // outside on the top
+ }
+ }
+
+ Box {
+ id: box
+
+ anchors.centerIn: undefined
+
+ YAnimator {
+ id: animation
+ target: box
+ from: 0;
+ to: 100
+ duration: 100
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/animators/tst_zeroduration.qml b/tests/auto/qmltest-blacklist/animators/tst_zeroduration.qml
new file mode 100644
index 0000000000..83ce235f42
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/animators/tst_zeroduration.qml
@@ -0,0 +1,35 @@
+import QtQuick 2.2
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 200
+ height: 200
+
+ TestCase {
+ id: testCase
+ name: "animators-y"
+ when: box.y == 100
+ function test_endresult() {
+ compare(box.yChangeCounter, 1);
+ var image = grabImage(root);
+ verify(image.pixel(0, 100) == Qt.rgba(1, 0, 0));
+ verify(image.pixel(0, 99) == Qt.rgba(1, 1, 1)); // outside on the top
+ }
+ }
+
+ Box {
+ id: box
+
+ anchors.centerIn: undefined
+
+ YAnimator {
+ id: animation
+ target: box
+ from: 0;
+ to: 100
+ duration: 0
+ running: true
+ }
+ }
+}
diff --git a/tests/auto/qmltest-blacklist/item/tst_layerInPositioner.qml b/tests/auto/qmltest-blacklist/item/tst_layerInPositioner.qml
new file mode 100644
index 0000000000..315ff0e5e0
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/item/tst_layerInPositioner.qml
@@ -0,0 +1,199 @@
+/****************************************************************************
+**
+** Copyright (C) 2014 Jolla Ltd, author: <gunnar.sletta@jollamobile.com>
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.4
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 400
+ height: 400
+
+ TestCase {
+ id: testCase
+ name: "transparentForPositioner"
+ when: windowShown
+ function test_endresult() {
+ var image = grabImage(root);
+
+ // Row of red, green, blue and white box inside blue
+ // At 10,10, spanning 10x10 pixels each
+ verify(image.pixel(10, 10) == Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(20, 10) == Qt.rgba(0, 1, 0, 1));
+ verify(image.pixel(30, 10) == Qt.rgba(0, 0, 1, 1));
+
+ // Column of red, green, blue and white box inside blue
+ // At 10,30, spanning 10x10 pixels each
+ verify(image.pixel(10, 30) == Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(10, 40) == Qt.rgba(0, 1, 0, 1));
+ verify(image.pixel(10, 50) == Qt.rgba(0, 0, 1, 1));
+
+ // Flow of red, green, blue and white box inside blue
+ // At 30,30, spanning 10x10 pixels each, wrapping after two boxes
+ verify(image.pixel(30, 30) == Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(40, 30) == Qt.rgba(0, 1, 0, 1));
+ verify(image.pixel(30, 40) == Qt.rgba(0, 0, 1, 1));
+
+ // Flow of red, green, blue and white box inside blue
+ // At 100,10, spanning 10x10 pixels each, wrapping after two boxes
+ verify(image.pixel(60, 10) == Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(70, 10) == Qt.rgba(0, 1, 0, 1));
+ verify(image.pixel(60, 20) == Qt.rgba(0, 0, 1, 1));
+ }
+ }
+
+ Component {
+ id: greenPassThrough
+ ShaderEffect {
+ fragmentShader:
+ "
+ uniform lowp sampler2D source;
+ varying highp vec2 qt_TexCoord0;
+ void main() {
+ gl_FragColor = texture2D(source, qt_TexCoord0) * vec4(0, 1, 0, 1);
+ }
+ "
+ }
+ }
+
+ Row {
+ id: theRow
+ x: 10
+ y: 10
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ff0000"
+ layer.enabled: true
+ }
+
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ffffff"
+ layer.enabled: true
+ layer.effect: greenPassThrough
+ }
+
+ Rectangle {
+ id: blueInRow
+ width: 10
+ height: 10
+ color: "#0000ff"
+ }
+ }
+
+ Column {
+ id: theColumn
+ x: 10
+ y: 30
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ff0000"
+ layer.enabled: true
+ }
+
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ffffff"
+ layer.enabled: true
+ layer.effect: greenPassThrough
+ }
+
+ Rectangle {
+ id: blueInColumn
+ width: 10
+ height: 10
+ color: "#0000ff"
+ }
+ }
+
+ Flow {
+ id: theFlow
+ x: 30
+ y: 30
+ width: 20
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ff0000"
+ layer.enabled: true
+ }
+
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ffffff"
+ layer.enabled: true
+ layer.effect: greenPassThrough
+ }
+
+ Rectangle {
+ id: blueInFlow
+ width: 10
+ height: 10
+ color: "#0000ff"
+ }
+ }
+
+ Grid {
+ id: theGrid
+ x: 60
+ y: 10
+ columns: 2
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ff0000"
+ layer.enabled: true
+ }
+
+ Rectangle {
+ width: 10
+ height: 10
+ color: "#ffffff"
+ layer.enabled: true
+ layer.effect: greenPassThrough
+ }
+
+ Rectangle {
+ id: blueInGrid
+ width: 10
+ height: 10
+ color: "#0000ff"
+ }
+ }
+
+}
diff --git a/tests/auto/qmltest-blacklist/itemgrabber/tst_itemgrabber.qml b/tests/auto/qmltest-blacklist/itemgrabber/tst_itemgrabber.qml
new file mode 100644
index 0000000000..5d65a1666c
--- /dev/null
+++ b/tests/auto/qmltest-blacklist/itemgrabber/tst_itemgrabber.qml
@@ -0,0 +1,152 @@
+/****************************************************************************
+**
+** Copyright (C) 2014 Jolla Ltd, author: <gunnar.sletta@jollamobile.com>
+** Contact: http://www.qt.io/licensing/
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL21$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and The Qt Company. For licensing terms
+** and conditions see http://www.qt.io/terms-conditions. For further
+** information use the contact form at http://www.qt.io/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 or version 3 as published by the Free
+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
+** following information to ensure the GNU Lesser General Public License
+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** As a special exception, The Qt Company gives you certain additional
+** rights. These rights are described in The Qt Company LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.4
+import QtTest 1.1
+
+Item {
+ id: root;
+ width: 400
+ height: 400
+
+ TestCase {
+ id: testCase
+ name: "item-grabber"
+ when: imageOnDisk.ready && imageOnDiskSmall.ready && imageInCache.ready && imageInCacheSmall.ready
+ function test_endresult() {
+ var image = grabImage(root);
+
+ // imageOnDisk at (0, 0) - (100x100)
+ compare(imageOnDisk.width, 100);
+ compare(imageOnDisk.height, 100);
+ verify(image.pixel(0, 0) === Qt.rgba(1, 0, 0, 1)); // Use verify because compare doesn't support colors (QTBUG-34878)
+ verify(image.pixel(99, 99) === Qt.rgba(0, 0, 1, 1));
+
+ // imageOnDiskSmall at (100, 0) - 50x50
+ compare(imageOnDiskSmall.width, 50);
+ compare(imageOnDiskSmall.height, 50);
+ verify(image.pixel(100, 0) === Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(149, 49) === Qt.rgba(0, 0, 1, 1));
+
+ // imageInCache at (0, 100) - 100x100
+ compare(imageInCache.width, 100);
+ compare(imageInCache.height, 100);
+ verify(image.pixel(0, 100) === Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(99, 199) === Qt.rgba(0, 0, 1, 1));
+
+ // imageInCacheSmall at (100, 100) - 50x50
+ compare(imageInCacheSmall.width, 50);
+ compare(imageInCacheSmall.height, 50);
+ verify(image.pixel(100, 100) === Qt.rgba(1, 0, 0, 1));
+ verify(image.pixel(149, 149) === Qt.rgba(0, 0, 1, 1));
+
+ // After all that has been going on, it should only have been called that one time..
+ compare(imageOnDisk.callCount, 1);
+ }
+
+ onWindowShownChanged: {
+ box.grabToImage(imageOnDisk.handleGrab);
+ box.grabToImage(imageOnDiskSmall.handleGrab, Qt.size(50, 50));
+ box.grabToImage(imageInCache.handleGrab);
+ box.grabToImage(imageInCacheSmall.handleGrab, Qt.size(50, 50));
+ }
+
+ }
+
+ Rectangle {
+ id: box
+ width: 100
+ height: 100
+ color: "red";
+
+ visible: false
+
+ Rectangle {
+ anchors.bottom: parent.bottom;
+ anchors.right: parent.right;
+ width: 10
+ height: 10
+ color: "blue";
+ }
+ }
+
+ Image {
+ id: imageOnDisk
+ x: 0
+ y: 0
+ property int callCount: 0;
+ property bool ready: false;
+ function handleGrab(result) {
+ if (!result.saveToFile("image.png"))
+ print("Error: Failed to save image to disk...");
+ source = "image.png";
+ ready = true;
+ ++callCount;
+ }
+ }
+
+ Image {
+ id: imageOnDiskSmall
+ x: 100
+ y: 0
+ property bool ready: false;
+ function handleGrab(result) {
+ if (!result.saveToFile("image_small.png"))
+ print("Error: Failed to save image to disk...");
+ source = "image_small.png";
+ ready = true;
+ }
+ }
+
+ Image {
+ id: imageInCache
+ x: 0
+ y: 100
+ property bool ready: false;
+ function handleGrab(result) {
+ source = result.url;
+ ready = true;
+ }
+ }
+
+ Image {
+ id: imageInCacheSmall
+ x: 100
+ y: 100
+ property bool ready: false;
+ function handleGrab(result) {
+ source = result.url;
+ ready = true;
+ }
+ }
+}