From 456f721917d07b3dd4259c324ff216f90bd32139 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 20 Oct 2015 10:08:39 +0200 Subject: tests/auto/corelib: Remove some placeholder formatting. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use QByteArray/QString addition instead in loops and for test row names. Change-Id: Ieffb429efdc14aa5932b3fcdef5a18e13a62d35f Reviewed-by: Jędrzej Nowacki --- tests/auto/corelib/tools/qline/tst_qline.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests/auto/corelib/tools/qline') diff --git a/tests/auto/corelib/tools/qline/tst_qline.cpp b/tests/auto/corelib/tools/qline/tst_qline.cpp index 20373bfb15..a215464d8a 100644 --- a/tests/auto/corelib/tools/qline/tst_qline.cpp +++ b/tests/auto/corelib/tools/qline/tst_qline.cpp @@ -179,7 +179,7 @@ void tst_QLine::testIntersection_data() a = a.translated(1, 1); b = b.translated(1, 1); - QTest::newRow(qPrintable(QString::fromLatin1("rotation-%0").arg(i))) + QTest::newRow(("rotation-" + QByteArray::number(i)).constData()) << (double)a.x1() << (double)a.y1() << (double)a.x2() << (double)a.y2() << (double)b.x1() << (double)b.y1() << (double)b.x2() << (double)b.y2() << int(QLineF::BoundedIntersection) @@ -332,7 +332,7 @@ void tst_QLine::testAngle_data() << 135.0; for (int i=0; i<180; ++i) { - QTest::newRow(QString("angle:%1").arg(i).toLatin1()) + QTest::newRow(("angle:" + QByteArray::number(i)).constData()) << 0.0 << 0.0 << double(cos(i*M_2PI/360)) << double(sin(i*M_2PI/360)) << 0.0 << 0.0 << 1.0 << 0.0 << double(i); @@ -460,7 +460,7 @@ void tst_QLine::testAngleTo_data() for (int i = 0; i < 360; ++i) { const QLineF l = QLineF::fromPolar(1, i); - QTest::newRow(QString("angle:%1").arg(i).toLatin1()) + QTest::newRow(("angle:" + QByteArray::number(i)).constData()) << qreal(0.0) << qreal(0.0) << qreal(1.0) << qreal(0.0) << qreal(0.0) << qreal(0.0) << l.p2().x() << l.p2().y() << qreal(i); -- cgit v1.2.3