1 #include <QtTest/QtTest>
2 #include <QtCore/QObject>
4 #include <ofononetworkoperator.h>
9 class TestOfonoNetworkOperator : public QObject
15 void statusChanged(QString status)
17 qDebug() << "statusChanged" << status;
20 void registerComplete(bool success)
22 qDebug() << "registerComplete:" << success;
27 m = new OfonoNetworkOperator("/phonesim/operator/23406", this);
28 connect(m, SIGNAL(registerComplete(bool)), this,
29 SLOT(registerComplete(bool)));
30 connect(m, SIGNAL(statusChanged(QString)),
32 SLOT(statusChanged(QString)));
35 void testOfonoNetworkOperator()
37 qDebug() << "name():" << m->name();
38 qDebug() << "status():" << m->status();
39 qDebug() << "mobileCountryCode():" << m->mcc();
40 qDebug() << "mobileNetworkCode():" << m->mnc();
41 qDebug() << "technologies():" << m->technologies();
42 qDebug() << "additionalInfo():" << m->additionalInfo();
49 void cleanupTestCase()
56 OfonoNetworkOperator *m;
59 QTEST_MAIN(TestOfonoNetworkOperator)
60 #include "test_ofononetworkoperator.moc"