components/serf/patches/fix-tests.patch
author xiao qing lu - Sun Microsystems - Beijing China <xiaoqing.lu@oracle.com>
Thu, 21 Jul 2016 18:08:07 -0700
changeset 6450 492d6d7286df
parent 5243 cb29cf94919d
child 7902 9e02778b84cd
permissions -rw-r--r--
24312696 libsigsegv upgrade breaks clients

Changes needed to get the serf tests to build on Solaris.
Remove a C++ style comment.
Run the tests in a fixed order.

These changes will be passed upstream.

--- serf-1.3.8/test/test_buckets.c.orig	2015-03-25 10:44:38.304724577 -0700
+++ serf-1.3.8/test/test_buckets.c	2015-03-25 10:45:28.821762949 -0700
@@ -1234,7 +1234,7 @@
        uncompressed data, + 12 bytes. This info comes from zlib.h.
        Note: This isn't sufficient when using Z_NO_FLUSH and extremely compressed
        data. Use a buffer bigger than what we need. */
-//    buf_size = orig_len + (orig_len / 1000) + 12;
+/*    buf_size = orig_len + (orig_len / 1000) + 12; */
     buf_size = 100000;
 
     write_buf = apr_palloc(pool, buf_size);
--- serf-1.3.8/build/check.py.orig	2015-03-25 11:55:50.065102813 -0700
+++ serf-1.3.8/build/check.py	2015-03-25 11:56:17.277942011 -0700
@@ -42,7 +42,7 @@
   TEST_ALL_EXE = os.path.join(testdir, TEST_ALL_EXE)
 
   # Find test responses and run them one by one
-  for case in glob.glob(testdir + "/testcases/*.response"):
+  for case in sorted(glob.glob(testdir + "/testcases/*.response")):
     print "== Testing %s ==" % (case)
     try:
       subprocess.check_call([SERF_RESPONSE_EXE, case])