Sfoglia il codice sorgente

Do not run ChildStream tests; ChildStream is deprecated.

Update test to verify that stdout and stderr from the child are
sent to the same destination.


git-svn-id: https://svn.microneil.com/svn/CodeDweller-Tests/trunk@52 b3372362-9eaa-4a85-aa2b-6faa1ab7c995
master
adeniz 9 anni fa
parent
commit
79d7d9a894
2 ha cambiato i file con 11 aggiunte e 3 eliminazioni
  1. 8
    2
      TestChild/childProgram.cpp
  2. 3
    1
      TestChild/testChild.cpp

+ 8
- 2
TestChild/childProgram.cpp Vedi File

@@ -16,8 +16,14 @@ main(int argc, char *argv[]) {
// Write a single line and exit.
if (std::string(argv[1]) == "write") {
log << "Command is \"write\". Returning \"This is a test\"" << std::endl;
std::cout << "This is a test";
log << "Command is \"write\". Returning \"This is a test\""
<< " to stdout and stderr." << std::endl;
std::cout << "This ";
std::cout.flush();
std::cerr << "is a";
std::cout << " test";
std::cout.flush();
if (!std::cout) {

+ 3
- 1
TestChild/testChild.cpp Vedi File

@@ -2020,6 +2020,8 @@ bool testChildReadDelimited() {
int main()
{
// ChildStream is not supported.
#if 0
std::cout << "\nCodeDweller::ChildStream unit tests\n" << std::endl;
RUN_TEST(testChildStreamIsDone);
@@ -2030,7 +2032,7 @@ int main()
RUN_TEST(testChildStreamReaderWriter);
RUN_TEST(testChildStreamBinaryRead);
RUN_TEST(testChildStreamNonBlockingRead);
#endif
std::cout << "\nCodeDweller::Child unit tests\n" << std::endl;
RUN_TEST(testChildIsDone);

Loading…
Annulla
Salva