summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp32
1 files changed, 1 insertions, 31 deletions
diff --git a/tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp b/tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp
index 5a3a54c..4a874be 100644
--- a/tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp
+++ b/tests/auto/qgraphicswidget/tst_qgraphicswidget.cpp
@@ -111,8 +111,6 @@ private slots:
void fontPropagationSceneChange();
void geometry_data();
void geometry();
- void width();
- void height();
void getContentsMargins_data();
void getContentsMargins();
void initStyleOption_data();
@@ -767,42 +765,14 @@ void tst_QGraphicsWidget::geometry()
{
SubQGraphicsWidget widget;
QCOMPARE(widget.geometry(), QRectF(widget.pos(), widget.size()));
- QSignalSpy spy(&widget, SIGNAL(geometryChanged()));
+
QFETCH(QPointF, pos);
QFETCH(QSizeF, size);
widget.setPos(pos);
widget.resize(size);
- if (!size.isNull())
- QCOMPARE(spy.count(), 1);
QCOMPARE(widget.geometry(), QRectF(pos, size));
}
-void tst_QGraphicsWidget::width()
-{
- QGraphicsWidget w;
- QCOMPARE(w.property("width").toReal(), qreal(0));
- QSignalSpy spy(&w, SIGNAL(widthChanged()));
- w.setProperty("width", qreal(50));
- QCOMPARE(w.property("width").toReal(), qreal(50));
- QCOMPARE(spy.count(), 1);
- //calling old school setGeometry should work too
- w.setGeometry(0, 0, 200, 200);
- QCOMPARE(spy.count(), 2);
-}
-
-void tst_QGraphicsWidget::height()
-{
- QGraphicsWidget w;
- QCOMPARE(w.property("height").toReal(), qreal(0));
- QSignalSpy spy(&w, SIGNAL(heightChanged()));
- w.setProperty("height", qreal(50));
- QCOMPARE(w.property("height").toReal(), qreal(50));
- QCOMPARE(spy.count(), 1);
- //calling old school setGeometry should work too
- w.setGeometry(0, 0, 200, 200);
- QCOMPARE(spy.count(), 2);
-}
-
void tst_QGraphicsWidget::getContentsMargins_data()
{
QTest::addColumn<qreal>("left");