Android: Fix QStandardPaths test
QStandardPaths::writableLocation() is documented to return the empty string if no matching writable location can be determined. This is the case for e.g. FontsLocation and ApplicationsLocation on Android. We need to still accept this as a valid response. Change-Id: I2824e9dcfd41b1c24dbf3896b7ae9b5260e9accd Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: BogDan Vatra <bogdan@kde.org>
This commit is contained in:
parent
0fb839ac62
commit
678a283498
@ -472,7 +472,7 @@ void tst_qstandardpaths::testAllWritableLocations()
|
||||
QString loc = QStandardPaths::writableLocation(location);
|
||||
if (loc.size() > 1) // workaround for unlikely case of locations that return '/'
|
||||
QCOMPARE(loc.endsWith(QLatin1Char('/')), false);
|
||||
QVERIFY(loc.contains(QLatin1Char('/')));
|
||||
QVERIFY(loc.isEmpty() || loc.contains(QLatin1Char('/')));
|
||||
QVERIFY(!loc.contains(QLatin1Char('\\')));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user