summaryrefslogtreecommitdiffstats
path: root/tests/auto/qprocess
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qprocess')
-rw-r--r--tests/auto/qprocess/qprocess.pro4
-rw-r--r--tests/auto/qprocess/test/test.pro100
-rw-r--r--tests/auto/qprocess/tst_qprocess.cpp23
3 files changed, 85 insertions, 42 deletions
diff --git a/tests/auto/qprocess/qprocess.pro b/tests/auto/qprocess/qprocess.pro
index 047828a..892686d 100644
--- a/tests/auto/qprocess/qprocess.pro
+++ b/tests/auto/qprocess/qprocess.pro
@@ -1,6 +1,8 @@
TEMPLATE = subdirs
-SUBDIRS = testProcessCrash \
+SUBDIRS = \
+ testBatFiles \
+ testProcessCrash \
testProcessEcho \
testProcessEcho2 \
testProcessEcho3 \
diff --git a/tests/auto/qprocess/test/test.pro b/tests/auto/qprocess/test/test.pro
index 82f91f8..e1afd22 100644
--- a/tests/auto/qprocess/test/test.pro
+++ b/tests/auto/qprocess/test/test.pro
@@ -26,29 +26,85 @@ QT = core
embedded: QT += gui
wince*: {
- addFiles.sources = \
- ../fileWriterProcess \
- "../test Space In Name" \
- ../testBatFiles \
- ../testDetached \
- ../testExitCodes \
- ../testGuiProcess \
- ../testProcessCrash \
- ../testProcessDeadWhileReading \
- ../testProcessEcho \
- ../testProcessEcho2 \
- ../testProcessEcho3 \
- ../testProcessEchoGui \
- ../testProcessEOF \
- ../testProcessLoopback \
- ../testProcessNormal \
- ../testProcessOutput \
- ../testProcessSpacesArgs \
- ../testSoftExit \
- ../testSpaceInName
+
+ addFile_fileWriterProcess.sources = $$OUT_PWD/../fileWriterProcess/fileWriterProcess.exe
+ addFile_fileWriterProcess.path = fileWriterProcess
+
+ addFile_testBatFiles.sources = $$PWD/../testBatFiles/*
+ addFile_testBatFiles.path = testBatFiles
+
+ addFile_testDetached.sources = $$OUT_PWD/../testDetached/testDetached.exe
+ addFile_testDetached.path = testDetached
+
+ addFile_testExitCodes.sources = $$OUT_PWD/../testExitCodes/testExitCodes.exe
+ addFile_testExitCodes.path = testExitCodes
+
+ addFile_testGuiProcess.sources = $$OUT_PWD/../testGuiProcess/testGuiProcess.exe
+ addFile_testGuiProcess.path = testGuiProcess
- addFiles.path = \Program Files\tst_qprocess
- DEPLOYMENT += addFiles
+ addFile_testProcessCrash.sources = $$OUT_PWD/../testProcessCrash/testProcessCrash.exe
+ addFile_testProcessCrash.path = testProcessCrash
+
+ addFile_testProcessDeadWhileReading.sources = $$OUT_PWD/../testProcessDeadWhileReading/testProcessDeadWhileReading.exe
+ addFile_testProcessDeadWhileReading.path = testProcessDeadWhileReading
+
+ addFile_testProcessEcho.sources = $$OUT_PWD/../testProcessEcho/testProcessEcho.exe
+ addFile_testProcessEcho.path = testProcessEcho
+
+ addFile_testProcessEcho2.sources = $$OUT_PWD/../testProcessEcho2/testProcessEcho2.exe
+ addFile_testProcessEcho2.path = testProcessEcho2
+
+ addFile_testProcessEcho3.sources = $$OUT_PWD/../testProcessEcho3/testProcessEcho3.exe
+ addFile_testProcessEcho3.path = testProcessEcho3
+
+ addFile_testProcessEOF.sources = $$OUT_PWD/../testProcessEOF/testProcessEOF.exe
+ addFile_testProcessEOF.path = testProcessEOF
+
+ addFile_testProcessLoopback.sources = $$OUT_PWD/../testProcessLoopback/testProcessLoopback.exe
+ addFile_testProcessLoopback.path = testProcessLoopback
+
+ addFile_testProcessNormal.sources = $$OUT_PWD/../testProcessNormal/testProcessNormal.exe
+ addFile_testProcessNormal.path = testProcessNormal
+
+ addFile_testProcessOutput.sources = $$OUT_PWD/../testProcessOutput/testProcessOutput.exe
+ addFile_testProcessOutput.path = testProcessOutput
+
+ addFile_testProcessNoSpacesArgs.sources = $$OUT_PWD/../testProcessSpacesArgs/nospace.exe
+ addFile_testProcessNoSpacesArgs.path = testProcessSpacesArgs
+
+ addFile_testProcessOneSpacesArgs.sources = $$OUT_PWD/../testProcessSpacesArgs/"one space".exe
+ addFile_testProcessOneSpacesArgs.path = testProcessSpacesArgs
+
+ addFile_testProcessTwoSpacesArgs.sources = $$OUT_PWD/../testProcessSpacesArgs/"two space s".exe
+ addFile_testProcessTwoSpacesArgs.path = testProcessSpacesArgs
+
+ addFile_testSoftExit.sources = $$OUT_PWD/../testSoftExit/testSoftExit.exe
+ addFile_testSoftExit.path = testSoftExit
+
+ addFile_testSpaceInName.sources = $$OUT_PWD/../"test Space In Name"/testSpaceInName.exe
+ addFile_testSpaceInName.path = "test Space In Name"
+
+
+ DEPLOYMENT += addFile_fileWriterProcess \
+ addFile_testBatFiles \
+ addFile_testDetached \
+ addFile_testExitCodes \
+ addFile_testGuiProcess \
+ addFile_testProcessCrash \
+ addFile_testProcessDeadWhileReading \
+ addFile_testProcessEcho \
+ addFile_testProcessEcho2 \
+ addFile_testProcessEcho3 \
+ addFile_testProcessEchoGui \
+ addFile_testProcessEOF \
+ addFile_testProcessLoopback \
+ addFile_testProcessNormal \
+ addFile_testProcessOutput \
+ addFile_testProcessNoSpacesArgs \
+ addFile_testProcessOneSpacesArgs \
+ addFile_testProcessTwoSpacesArgs \
+ addFile_testSoftExit \
+ addFile_testSpaceInName
}
symbian: {
diff --git a/tests/auto/qprocess/tst_qprocess.cpp b/tests/auto/qprocess/tst_qprocess.cpp
index e759b0e..d5bc0bd 100644
--- a/tests/auto/qprocess/tst_qprocess.cpp
+++ b/tests/auto/qprocess/tst_qprocess.cpp
@@ -1318,15 +1318,6 @@ protected slots:
private:
int exitCode;
-#ifdef Q_OS_SYMBIAN
- enum
- {
- /**
- * The maximum stack size.
- */
- SymbianStackSize = 0x14000
- };
-#endif
};
//-----------------------------------------------------------------------------
@@ -1334,9 +1325,6 @@ void tst_QProcess::processInAThread()
{
for (int i = 0; i < 10; ++i) {
TestThread thread;
-#if defined(Q_OS_SYMBIAN)
- thread.setStackSize(SymbianStackSize);
-#endif
thread.start();
QVERIFY(thread.wait(10000));
QCOMPARE(thread.code(), 0);
@@ -1359,10 +1347,6 @@ void tst_QProcess::processesInMultipleThreads()
thread1.serial = serialCounter++;
thread2.serial = serialCounter++;
thread3.serial = serialCounter++;
-
- thread1.setStackSize(SymbianStackSize);
- thread2.setStackSize(SymbianStackSize);
- thread3.setStackSize(SymbianStackSize);
#endif
thread1.start();
thread2.start();
@@ -1884,8 +1868,10 @@ void tst_QProcess::setProcessEnvironment_data()
void tst_QProcess::setProcessEnvironment()
{
-#if !defined (Q_OS_WINCE)
- // there is no concept of system variables on Windows CE as there is no console
+#if defined (Q_OS_WINCE) || defined(Q_OS_SYMBIAN)
+ QSKIP("OS doesn't support environment variables", SkipAll);
+#endif
+
// make sure our environment variables are correct
QVERIFY(qgetenv("tst_QProcess").isEmpty());
QVERIFY(!qgetenv("PATH").isEmpty());
@@ -1915,7 +1901,6 @@ void tst_QProcess::setProcessEnvironment()
QCOMPARE(process.readAll(), value.toLocal8Bit());
}
-#endif
}
//-----------------------------------------------------------------------------
void tst_QProcess::systemEnvironment()