summaryrefslogtreecommitdiff
path: root/tests/auto/qml
diff options
context:
space:
mode:
authorTim Jenssen <tim.jenssen@qt.io>2016-12-23 16:13:14 +0100
committerTim Jenssen <tim.jenssen@qt.io>2017-01-06 11:26:27 +0000
commit5ad0cbc070fc1536a358b63d17261dfba03c8230 (patch)
tree06ab9dcb63c31d3cc50d512b20d34d1b40c5b798 /tests/auto/qml
parent2ea7119b6989ff2c6098217f959681dac14a71cd (diff)
downloadqt-creator-5ad0cbc070fc1536a358b63d17261dfba03c8230.tar.gz
QmlDesigner: remove unnecessary save method
Change-Id: Ia2a195c84ce83bc3a83155cc19b0585475a5547a Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Diffstat (limited to 'tests/auto/qml')
-rw-r--r--tests/auto/qml/qmldesigner/coretests/tst_testcore.cpp8
1 files changed, 1 insertions, 7 deletions
diff --git a/tests/auto/qml/qmldesigner/coretests/tst_testcore.cpp b/tests/auto/qml/qmldesigner/coretests/tst_testcore.cpp
index b14912b4d6..49171320ad 100644
--- a/tests/auto/qml/qmldesigner/coretests/tst_testcore.cpp
+++ b/tests/auto/qml/qmldesigner/coretests/tst_testcore.cpp
@@ -380,11 +380,6 @@ void tst_TestCore::saveEmptyCoreModel()
testRewriterView1->setTextModifier(&modifier1);
model1->attachView(testRewriterView1.data());
-
- QBuffer buffer;
- buffer.open(QIODevice::ReadWrite | QIODevice::Text);
- modifier1.save(&buffer);
-
QPlainTextEdit textEdit2;
textEdit2.setPlainText("import QtQuick 1.1; Item{}");
NotIndentingTextEditModifier modifier2(&textEdit2);
@@ -396,7 +391,6 @@ void tst_TestCore::saveEmptyCoreModel()
model2->attachView(testRewriterView2.data());
QVERIFY(compareTree(testRewriterView1->rootModelNode(), testRewriterView2->rootModelNode()));
-
}
void tst_TestCore::loadAttributesInCoreModel()
@@ -453,7 +447,7 @@ void tst_TestCore::saveAttributesInCoreModel()
QBuffer buffer;
buffer.open(QIODevice::ReadWrite | QIODevice::Text);
- modifier1.save(&buffer);
+ buffer.write(modifier1.textDocument()->toPlainText().toUtf8());
QPlainTextEdit textEdit2;
textEdit2.setPlainText(QString::fromUtf8(buffer.data()));