aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/tools
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2018-04-30 14:48:54 +0200
committerJoerg Bornemann <joerg.bornemann@qt.io>2018-05-02 12:15:30 +0000
commita72ffb709f7d0ec54523d53181294981ad7bf0ec (patch)
treed1f668bc823fb06ade4f9acf03294d279cbcdb35 /tests/auto/tools
parent704b5fa7e8cbe4248be775a40f05c571ad27bec2 (diff)
Add FileInfo.suffix and FileInfo.completeSuffix
[ChangeLog] Added FileInfo.suffix and FileInfo.completeSuffix. Change-Id: Ic74a2fcff2f3f1271fa60ac33b96a4c5a4d0e93d Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'tests/auto/tools')
-rw-r--r--tests/auto/tools/tst_tools.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/tools/tst_tools.cpp b/tests/auto/tools/tst_tools.cpp
index 44f4303e3..deb7692cd 100644
--- a/tests/auto/tools/tst_tools.cpp
+++ b/tests/auto/tools/tst_tools.cpp
@@ -206,6 +206,8 @@ void TestTools::testFileInfo()
QCOMPARE(FileInfo::fileName("C:/waffl/copter.exe"), QString("copter.exe"));
QCOMPARE(FileInfo::baseName("C:/waffl/copter.exe.lib"), QString("copter"));
QCOMPARE(FileInfo::completeBaseName("C:/waffl/copter.exe.lib"), QString("copter.exe"));
+ QCOMPARE(FileInfo::suffix("C:/waffl/copter.exe.lib"), QString("lib"));
+ QCOMPARE(FileInfo::completeSuffix("C:/waffl/copter.exe.lib"), QString("exe.lib"));
QCOMPARE(FileInfo::path("abc"), QString("."));
QCOMPARE(FileInfo::path("/abc/lol"), QString("/abc"));
QCOMPARE(FileInfo::path("/fileInRoot"), QString(QLatin1Char('/')));