aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/quick/qquickrectangle/data/gradient-border.qml21
-rw-r--r--tests/auto/quick/qquickrectangle/tst_qquickrectangle.cpp11
2 files changed, 32 insertions, 0 deletions
diff --git a/tests/auto/quick/qquickrectangle/data/gradient-border.qml b/tests/auto/quick/qquickrectangle/data/gradient-border.qml
new file mode 100644
index 0000000000..1d45fb2799
--- /dev/null
+++ b/tests/auto/quick/qquickrectangle/data/gradient-border.qml
@@ -0,0 +1,21 @@
+import QtQuick 2.0
+
+Item {
+ Rectangle {
+ width: 100
+ height: 100
+ border.width: 10
+ radius: 10
+
+ gradient: Gradient {
+ GradientStop {
+ position: 0.00
+ color: '#ffffff'
+ }
+ GradientStop {
+ position: 0.94
+ color: '#000000'
+ }
+ }
+ }
+}
diff --git a/tests/auto/quick/qquickrectangle/tst_qquickrectangle.cpp b/tests/auto/quick/qquickrectangle/tst_qquickrectangle.cpp
index 8a24636647..a7e82e272f 100644
--- a/tests/auto/quick/qquickrectangle/tst_qquickrectangle.cpp
+++ b/tests/auto/quick/qquickrectangle/tst_qquickrectangle.cpp
@@ -35,6 +35,7 @@
#include <QtQml/qqmlengine.h>
#include <QtQml/qqmlcomponent.h>
+#include <QtQuick/qquickview.h>
#include <private/qquickrectangle_p.h>
#include "../../shared/util.h"
@@ -47,6 +48,7 @@ public:
private slots:
void gradient();
+ void gradient_border();
void antialiasing();
private:
@@ -88,6 +90,15 @@ void tst_qquickrectangle::gradient()
delete rect;
}
+void tst_qquickrectangle::gradient_border()
+{
+ QQuickView view;
+ view.setSource(testFileUrl("gradient-border.qml"));
+ view.show();
+
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
+}
+
void tst_qquickrectangle::antialiasing()
{
QQmlComponent component(&engine);