From c8416cc79e9b31a53ad1e0e2f095aa813e8019e6 Mon Sep 17 00:00:00 2001 From: Arvid Norberg Date: Fri, 21 Mar 2008 05:54:01 +0000 Subject: [PATCH] fixed http_connection test (stopped working with new echo semantics in leopard) --- test/main.cpp | 2 +- test/setup_transfer.cpp | 13 +++++++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/test/main.cpp b/test/main.cpp index 4d146a4a3..7416511eb 100644 --- a/test/main.cpp +++ b/test/main.cpp @@ -6,7 +6,7 @@ bool tests_failure = false; void report_failure(char const* err, char const* file, int line) { - std::cerr << file << ":" << line << "\"" << err << "\"\n"; + std::cerr << "\033[31m" << file << ":" << line << " \"" << err << "\"\033[0m\n"; tests_failure = true; } diff --git a/test/setup_transfer.cpp b/test/setup_transfer.cpp index d4d696c6f..12b7fccfe 100644 --- a/test/setup_transfer.cpp +++ b/test/setup_transfer.cpp @@ -73,10 +73,15 @@ void start_web_server(int port, bool ssl) if (ssl) { - system("echo -e \"AU\\ntest province\\ntest city\\ntest company\\n" - "test department\\ntester\\ntest@test.com\" | " - "openssl req -new -x509 -keyout server.pem -out server.pem " - "-days 365 -nodes"); + system("echo . > tmp"); + system("echo test province >>tmp"); + system("echo test city >> tmp"); + system("echo test company >> tmp"); + system("echo test department >> tmp"); + system("echo tester >> tmp"); + system("echo test@test.com >> tmp"); + system("openssl req -new -x509 -keyout server.pem -out server.pem " + "-days 365 -nodes