aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/corelib/tools/tst_tools.cpp
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@theqtcompany.com>2015-04-17 11:02:05 +0200
committerJoerg Bornemann <joerg.bornemann@theqtcompany.com>2015-04-27 11:15:17 +0000
commit81dd9e15e90328e2bb8806f53647bc95f4946113 (patch)
tree164ed73975fca46150d61b415b45ca24e9e73872 /src/lib/corelib/tools/tst_tools.cpp
parent2a0772a19c6b47f1441dc45e91cca78f98e0ed83 (diff)
add a function to retrieve the process name by pid
This will be used by the build graph locker in a subsequent commit. Change-Id: If8cb901c692a21953559ea4f35ea29e25a9b0114 Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
Diffstat (limited to 'src/lib/corelib/tools/tst_tools.cpp')
-rw-r--r--src/lib/corelib/tools/tst_tools.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lib/corelib/tools/tst_tools.cpp b/src/lib/corelib/tools/tst_tools.cpp
index 4d1686f84..72ddf383f 100644
--- a/src/lib/corelib/tools/tst_tools.cpp
+++ b/src/lib/corelib/tools/tst_tools.cpp
@@ -36,6 +36,7 @@
#include "error.h"
#include "fileinfo.h"
#include "hostosinfo.h"
+#include "processutils.h"
#include "profile.h"
#include "settings.h"
#include "setupprojectparameters.h"
@@ -168,5 +169,10 @@ void TestTools::testBuildConfigMerging()
QCOMPARE(finalCppMap.value(QLatin1String("treatWarningsAsErrors")).toBool(), true);
}
+void TestTools::testProcessNameByPid()
+{
+ QCOMPARE(qAppName(), processNameByPid(QCoreApplication::applicationPid()));
+}
+
} // namespace Internal
} // namespace qbs