mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-29 04:17:55 +01:00
disable isRunning test on WinCE
This commit is contained in:
@@ -93,37 +93,6 @@ void ProcessTest::testLaunchRedirectIn()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void ProcessTest::testIsRunning()
|
|
||||||
{
|
|
||||||
std::string name("TestApp");
|
|
||||||
std::string cmd;
|
|
||||||
#if defined(_DEBUG)
|
|
||||||
name += "d";
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(POCO_OS_FAMILY_UNIX)
|
|
||||||
cmd = "./";
|
|
||||||
cmd += name;
|
|
||||||
#else
|
|
||||||
cmd = name;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
std::vector<std::string> args;
|
|
||||||
args.push_back("-count");
|
|
||||||
Pipe inPipe;
|
|
||||||
ProcessHandle ph = Process::launch(cmd, args, &inPipe, 0, 0);
|
|
||||||
Process::PID id = ph.id();
|
|
||||||
assert (Process::isRunning(ph));
|
|
||||||
assert (Process::isRunning(id));
|
|
||||||
PipeOutputStream ostr(inPipe);
|
|
||||||
ostr << std::string(100, 'x');
|
|
||||||
ostr.close();
|
|
||||||
int rc = ph.wait();
|
|
||||||
assert (!Process::isRunning(ph));
|
|
||||||
assert (!Process::isRunning(id));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void ProcessTest::testLaunchRedirectOut()
|
void ProcessTest::testLaunchRedirectOut()
|
||||||
{
|
{
|
||||||
#if !defined(_WIN32_WCE)
|
#if !defined(_WIN32_WCE)
|
||||||
@@ -188,6 +157,39 @@ void ProcessTest::testLaunchEnv()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void ProcessTest::testIsRunning()
|
||||||
|
{
|
||||||
|
#if !defined(_WIN32_WCE)
|
||||||
|
std::string name("TestApp");
|
||||||
|
std::string cmd;
|
||||||
|
#if defined(_DEBUG)
|
||||||
|
name += "d";
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(POCO_OS_FAMILY_UNIX)
|
||||||
|
cmd = "./";
|
||||||
|
cmd += name;
|
||||||
|
#else
|
||||||
|
cmd = name;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
std::vector<std::string> args;
|
||||||
|
args.push_back("-count");
|
||||||
|
Pipe inPipe;
|
||||||
|
ProcessHandle ph = Process::launch(cmd, args, &inPipe, 0, 0);
|
||||||
|
Process::PID id = ph.id();
|
||||||
|
assert (Process::isRunning(ph));
|
||||||
|
assert (Process::isRunning(id));
|
||||||
|
PipeOutputStream ostr(inPipe);
|
||||||
|
ostr << std::string(100, 'x');
|
||||||
|
ostr.close();
|
||||||
|
int rc = ph.wait();
|
||||||
|
assert (!Process::isRunning(ph));
|
||||||
|
assert (!Process::isRunning(id));
|
||||||
|
#endif // !defined(_WIN32_WCE)
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void ProcessTest::setUp()
|
void ProcessTest::setUp()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user