You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by ro...@apache.org on 2014/05/02 21:08:50 UTC

git commit: THRIFT-847 Test Framework harmonization across all languages

Repository: thrift
Updated Branches:
  refs/heads/master 099725074 -> 4edac7ff0


THRIFT-847 Test Framework harmonization across all languages

- no verbose output, use log/error.log instead
- improve test/README.md

Patch: Roger Meier


Project: http://git-wip-us.apache.org/repos/asf/thrift/repo
Commit: http://git-wip-us.apache.org/repos/asf/thrift/commit/4edac7ff
Tree: http://git-wip-us.apache.org/repos/asf/thrift/tree/4edac7ff
Diff: http://git-wip-us.apache.org/repos/asf/thrift/diff/4edac7ff

Branch: refs/heads/master
Commit: 4edac7ff085e4bd28096fef3cf8234e4991544ff
Parents: 0997250
Author: Roger Meier <ro...@apache.org>
Authored: Fri May 2 21:07:01 2014 +0200
Committer: Roger Meier <ro...@apache.org>
Committed: Fri May 2 21:07:01 2014 +0200

----------------------------------------------------------------------
 test/README.md |  6 +++---
 test/test.sh   | 22 ++++++++++++++--------
 2 files changed, 17 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/thrift/blob/4edac7ff/test/README.md
----------------------------------------------------------------------
diff --git a/test/README.md b/test/README.md
index dd27a42..d6c7ba0 100755
--- a/test/README.md
+++ b/test/README.md
@@ -44,9 +44,9 @@ and this for clients:
 If you have executed the **make check** or **make cross** then you will be able to browse
 [gen-html/ThriftTest.html](gen-html/ThriftTest.html) with the test documentation.
 
+return code shall be 0 on success or an integer in the range 1 - 255 on error
+
 ## SSL
 Test Keys and Certificates are provided in multiple formats under the following
-directory
-
-    test/keys
+directory [test/keys](test/keys)
 

http://git-wip-us.apache.org/repos/asf/thrift/blob/4edac7ff/test/test.sh
----------------------------------------------------------------------
diff --git a/test/test.sh b/test/test.sh
index 43ec883..90ec5a6 100755
--- a/test/test.sh
+++ b/test/test.sh
@@ -68,13 +68,15 @@ do_test () {
       echo " success"
     else
       echo " failure"
-      echo "=================== server message ==================="
-      tail log/${testname}_server.log 
-      echo "=================== client message ==================="
-      tail log/${testname}_client.log
-      echo "======================================================"
-      echo ""
-      print_header
+      # add details to the error.log
+      print_header >> log/error.log
+      printf "%-16s %-11s %-17s\n" ${client_server} ${protocol} ${transport} >> log/error.log
+      echo "=================== server message ===================" >> log/error.log
+      tail log/${testname}_server.log  >> log/error.log
+      echo "=================== client message ===================" >> log/error.log
+      tail log/${testname}_client.log >> log/error.log
+      echo "======================================================" >> log/error.log
+      echo "" >> log/error.log
     fi
 
     # silently kill server
@@ -276,7 +278,7 @@ do_test "java-py"  "binary" "buffered-ip" \
         "ant -f  ../lib/java/build.xml -Dno-gen-thrift=\"\" run-testclient" \
         "py/TestServer.py --proto=binary --port=9090 --genpydir=py/gen-py TSimpleServer" \
         "10" "5"
-do_test "js-java"   "json "  "http-ip" \
+do_test "js-java"   "json"  "http-ip" \
         "" \
         "ant -f  ../lib/js/test/build.xml unittest" \
         "2" "2"
@@ -296,4 +298,8 @@ do_test "rb-rb" "binary-accl" "buffered-ip" \
         "ruby rb/integration/accelerated_buffered_client.rb" \
         "ruby rb/integration/accelerated_buffered_server.rb" \
         "5" "5"
+
+echo " failed tests are logged to test/log/error.log"
+echo " full log is here test/log/client_server_protocol_transport.log"
+date
 cd -