aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYann Bodson <yann.bodson@nokia.com>2011-05-18 13:21:39 +1000
committerYann Bodson <yann.bodson@nokia.com>2011-05-18 13:23:05 +1000
commita183d3a0362bd09073f5a33d628cdc6658ae2663 (patch)
tree9bfad4bc49727deee6423d9a42ce3c49241af630
parent616c7e768f3d88f6b8be6af72290769e99500e72 (diff)
Fix QSGBorderImage autotest.
QtQuick 1.0 -> QtQuick 2.0
-rw-r--r--tests/auto/declarative/qsgborderimage/tst_qsgborderimage.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/auto/declarative/qsgborderimage/tst_qsgborderimage.cpp b/tests/auto/declarative/qsgborderimage/tst_qsgborderimage.cpp
index cdf2f62069..8fd40e3138 100644
--- a/tests/auto/declarative/qsgborderimage/tst_qsgborderimage.cpp
+++ b/tests/auto/declarative/qsgborderimage/tst_qsgborderimage.cpp
@@ -98,7 +98,7 @@ tst_qsgborderimage::tst_qsgborderimage()
void tst_qsgborderimage::noSource()
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"\" }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"\" }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -142,7 +142,7 @@ void tst_qsgborderimage::imageSource()
if (!error.isEmpty())
QTest::ignoreMessage(QtWarningMsg, error.toUtf8());
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" + source + "\" }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" + source + "\" }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -171,7 +171,7 @@ void tst_qsgborderimage::imageSource()
void tst_qsgborderimage::clearSource()
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: srcImage }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: srcImage }";
QDeclarativeContext *ctxt = engine.rootContext();
ctxt->setContextProperty("srcImage", QUrl::fromLocalFile(SRCDIR "/data/colors.png"));
QDeclarativeComponent component(&engine);
@@ -191,7 +191,7 @@ void tst_qsgborderimage::clearSource()
void tst_qsgborderimage::resized()
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" + QUrl::fromLocalFile(SRCDIR "/data/colors.png").toString() + "\"; width: 300; height: 300 }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" + QUrl::fromLocalFile(SRCDIR "/data/colors.png").toString() + "\"; width: 300; height: 300 }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -208,7 +208,7 @@ void tst_qsgborderimage::resized()
void tst_qsgborderimage::smooth()
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; smooth: true; width: 300; height: 300 }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; smooth: true; width: 300; height: 300 }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -247,7 +247,7 @@ void tst_qsgborderimage::mirror()
void tst_qsgborderimage::tileModes()
{
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; width: 100; height: 300; horizontalTileMode: BorderImage.Repeat; verticalTileMode: BorderImage.Repeat }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; width: 100; height: 300; horizontalTileMode: BorderImage.Repeat; verticalTileMode: BorderImage.Repeat }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -260,7 +260,7 @@ void tst_qsgborderimage::tileModes()
delete obj;
}
{
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; width: 300; height: 150; horizontalTileMode: BorderImage.Round; verticalTileMode: BorderImage.Round }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" SRCDIR "/data/colors.png\"; width: 300; height: 150; horizontalTileMode: BorderImage.Round; verticalTileMode: BorderImage.Round }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -287,7 +287,7 @@ void tst_qsgborderimage::sciSource()
server->serveDirectory(SRCDIR "/data");
}
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" + source + "\"; width: 300; height: 300 }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" + source + "\"; width: 300; height: 300 }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -333,7 +333,7 @@ void tst_qsgborderimage::invalidSciFile()
QTest::ignoreMessage(QtWarningMsg, "QSGGridScaledImage: Invalid tile rule specified. Using Stretch."); // for "Roun"
QTest::ignoreMessage(QtWarningMsg, "QSGGridScaledImage: Invalid tile rule specified. Using Stretch."); // for "Repea"
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" + QUrl::fromLocalFile(SRCDIR "/data/invalid.sci").toString() +"\"; width: 300; height: 300 }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" + QUrl::fromLocalFile(SRCDIR "/data/invalid.sci").toString() +"\"; width: 300; height: 300 }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());
@@ -351,7 +351,7 @@ void tst_qsgborderimage::pendingRemoteRequest()
{
QFETCH(QString, source);
- QString componentStr = "import QtQuick 1.0\nBorderImage { source: \"" + source + "\" }";
+ QString componentStr = "import QtQuick 2.0\nBorderImage { source: \"" + source + "\" }";
QDeclarativeComponent component(&engine);
component.setData(componentStr.toLatin1(), QUrl::fromLocalFile(""));
QSGBorderImage *obj = qobject_cast<QSGBorderImage*>(component.create());