| 119 | } |
| 120 | |
| 121 | void MQTTTest::testCommonFalse() { |
| 122 | auto* client = new MQTTClient(QStringLiteral("test")); |
| 123 | const QString fileName = m_dataDir + QStringLiteral("common_false.txt"); |
| 124 | QFile file(fileName); |
| 125 | |
| 126 | if (file.open(QIODevice::ReadOnly)) { |
| 127 | QTextStream in(&file); |
| 128 | |
| 129 | while (!in.atEnd()) { |
| 130 | QString line = in.readLine(); |
| 131 | auto topics = line.split(QLatin1Char(' '), Qt::SkipEmptyParts); |
| 132 | QCOMPARE(client->checkCommonLevel(topics[0], topics[1]), QString()); |
| 133 | } |
| 134 | |
| 135 | delete client; |
| 136 | file.close(); |
| 137 | } |
| 138 | } |
| 139 | |
| 140 | // ############################################################################## |
| 141 | // ################# test handling of data received by messages ############### |