You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ic...@apache.org on 2017/05/29 09:03:51 UTC

svn commit: r1796599 - in /httpd/test/mod_h2/trunk: configure.ac test/test.sh test/test_common.sh test/test_curl_post.sh test/test_debug.sh test/test_fuzz.sh test/test_nghttp_post.sh test/test_proxy.sh test/test_trailer.sh test/test_window_update.sh

Author: icing
Date: Mon May 29 09:03:50 2017
New Revision: 1796599

URL: http://svn.apache.org/viewvc?rev=1796599&view=rev
Log:
upload data generation now on demand, allowing arbitrary test case ordering, updated ssl and libev versions

Modified:
    httpd/test/mod_h2/trunk/configure.ac
    httpd/test/mod_h2/trunk/test/test.sh
    httpd/test/mod_h2/trunk/test/test_common.sh
    httpd/test/mod_h2/trunk/test/test_curl_post.sh
    httpd/test/mod_h2/trunk/test/test_debug.sh
    httpd/test/mod_h2/trunk/test/test_fuzz.sh
    httpd/test/mod_h2/trunk/test/test_nghttp_post.sh
    httpd/test/mod_h2/trunk/test/test_proxy.sh
    httpd/test/mod_h2/trunk/test/test_trailer.sh
    httpd/test/mod_h2/trunk/test/test_window_update.sh

Modified: httpd/test/mod_h2/trunk/configure.ac
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/configure.ac?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/configure.ac (original)
+++ httpd/test/mod_h2/trunk/configure.ac Mon May 29 09:03:50 2017
@@ -267,9 +267,9 @@ fi
 # openssl 
 ################################################################################
 
-OPENSSL_VERSION=1.1.0e
+OPENSSL_VERSION=1.0.2l
 LIBEVENT_VERSION=2.0.22-stable
-LIBEV_VERSION=4.22
+LIBEV_VERSION=4.24
 ZLIB_VERSION=1.2.11
 
 if test "x$ac_cv_nghttp2" != "xyes"; then

Modified: httpd/test/mod_h2/trunk/test/test.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test.sh (original)
+++ httpd/test/mod_h2/trunk/test/test.sh Mon May 29 09:03:50 2017
@@ -207,6 +207,10 @@ HTTPS_AUTH_SER=https://$HOST_NAME_SER:$H
 
 export CURL="$CURL"
 
+if test -d "$GEN"; then
+    rm -rf "$GEN"/data* "$GEN"/tmp
+fi
+
 if test -n "$suites"; then
     echo "suites: $suites" >&2
     for suite in $( echo $suites | tr , ' ' ); do

Modified: httpd/test/mod_h2/trunk/test/test_common.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_common.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_common.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_common.sh Mon May 29 09:03:50 2017
@@ -739,3 +739,39 @@ h2load_check_requests() {
     diff -u $TMP/expected $TMP/requests || fail "$(cat $TMP/result)"
     echo ok.
 }
+
+####################################################################################################
+# common test files for uploads
+
+test_gen_data() {
+    local CHR100="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
+"
+
+    if [ ! -f $GEN/data-1k ]; then
+        i=0; while [ $i -lt 10 ]; do
+            echo -n "$CHR100"
+            i=$[ i + 1 ]
+        done > $GEN/data-1k
+    fi
+
+    if [ ! -f $GEN/data-10k ]; then
+        i=0; while [ $i -lt 10 ]; do
+            cat $GEN/data-1k
+            i=$[ i + 1 ]
+        done  > $GEN/data-10k
+    fi
+
+    if [ ! -f $GEN/data-100k ]; then
+        i=0; while [ $i -lt 10 ]; do
+            cat $GEN/data-10k
+            i=$[ i + 1 ]
+        done > $GEN/data-100k
+    fi
+
+    if [ ! -f $GEN/data-1m ]; then
+        i=0; while [ $i -lt 10 ]; do
+            cat $GEN/data-100k
+            i=$[ i + 1 ]
+        done > $GEN/data-1m
+    fi
+}

Modified: httpd/test/mod_h2/trunk/test/test_curl_post.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_curl_post.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_curl_post.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_curl_post.sh Mon May 29 09:03:50 2017
@@ -17,36 +17,7 @@
 source $(dirname $0)/test_common.sh
 echo "curl POST on: $@"
 
-CHR100="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
-"
-
-if [ ! -f $GEN/data-1k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        echo -n "$CHR100"
-        i=$[ i + 1 ]
-    done > $GEN/data-1k
-fi
-
-if [ ! -f $GEN/data-10k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-1k
-        i=$[ i + 1 ]
-    done  > $GEN/data-10k
-fi
-
-if [ ! -f $GEN/data-100k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-10k
-        i=$[ i + 1 ]
-    done > $GEN/data-100k
-fi
-
-if [ ! -f $GEN/data-1m ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-100k
-        i=$[ i + 1 ]
-    done > $GEN/data-1m
-fi
+test_gen_data
 
 # just a check that things are working
 curl_post_data upload.py $GEN/data-1k "file upload via http/1.1" --http1.1

Modified: httpd/test/mod_h2/trunk/test/test_debug.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_debug.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_debug.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_debug.sh Mon May 29 09:03:50 2017
@@ -132,14 +132,7 @@ curl_check_debug .well-known/h2/state "c
 }
 EOF
 
-CHR98="0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456
-"
-rm -f $GEN/data-1k
-
-i=0; while [ $i -lt 10 ]; do
-    echo -n "$( printf '%01d' $i) $CHR98"
-    i=$[ i + 1 ]
-done > $GEN/data-1k
+test_gen_data
 
 # check that incoming trailers are seen in POST requests
 nghttp_post_debug .well-known/h2/state $GEN/data-1k "1 trailer (POST)" --trailer "test: 1" -v <<EOF

Modified: httpd/test/mod_h2/trunk/test/test_fuzz.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_fuzz.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_fuzz.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_fuzz.sh Mon May 29 09:03:50 2017
@@ -56,36 +56,8 @@ do-upload() {
 
 fuzz-upload() {
     URL_PREFIX="$1"
-    local CHR100="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
-"
 
-    if [ ! -f $GEN/data-1k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            echo -n "$CHR100"
-            i=$[ i + 1 ]
-        done > $GEN/data-1k
-    fi
-
-    if [ ! -f $GEN/data-10k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-1k
-            i=$[ i + 1 ]
-        done  > $GEN/data-10k
-    fi
-
-    if [ ! -f $GEN/data-100k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-10k
-            i=$[ i + 1 ]
-        done > $GEN/data-100k
-    fi
-
-    if [ ! -f $GEN/data-1m ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-100k
-            i=$[ i + 1 ]
-        done > $GEN/data-1m
-    fi
+    test_gen_data
     
     do-upload 1k 32
     do-upload 10k 32

Modified: httpd/test/mod_h2/trunk/test/test_nghttp_post.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_nghttp_post.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_nghttp_post.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_nghttp_post.sh Mon May 29 09:03:50 2017
@@ -17,36 +17,7 @@
 source $(dirname $0)/test_common.sh
 echo "nghttp POST on: $@"
 
-CHR100="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
-"
-
-if [ ! -f $GEN/data-1k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        echo -n "$CHR100"
-        i=$[ i + 1 ]
-    done > $GEN/data-1k
-fi
-
-if [ ! -f $GEN/data-10k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-1k
-        i=$[ i + 1 ]
-    done  > $GEN/data-10k
-fi
-
-if [ ! -f $GEN/data-100k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-10k
-        i=$[ i + 1 ]
-    done > $GEN/data-100k
-fi
-
-if [ ! -f $GEN/data-1m ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-100k
-        i=$[ i + 1 ]
-    done > $GEN/data-1m
-fi
+test_gen_data
 
 # Tests witht the nghttp client that *requires* h2/h2c. Sends "OPTIONS *"
 # on h2c which is a good test.

Modified: httpd/test/mod_h2/trunk/test/test_proxy.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_proxy.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_proxy.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_proxy.sh Mon May 29 09:03:50 2017
@@ -83,36 +83,8 @@ do-upload() {
 
 large-upload() {
     URL_PREFIX="$1"
-    local CHR100="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678
-"
-
-    if [ ! -f $GEN/data-1k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            echo -n "$CHR100"
-            i=$[ i + 1 ]
-        done > $GEN/data-1k
-    fi
-
-    if [ ! -f $GEN/data-10k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-1k
-            i=$[ i + 1 ]
-        done  > $GEN/data-10k
-    fi
-
-    if [ ! -f $GEN/data-100k ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-10k
-            i=$[ i + 1 ]
-        done > $GEN/data-100k
-    fi
-
-    if [ ! -f $GEN/data-1m ]; then
-        i=0; while [ $i -lt 10 ]; do
-            cat $GEN/data-100k
-            i=$[ i + 1 ]
-        done > $GEN/data-1m
-    fi
+    
+    test_gen_data
     
     echo "curl upload to $URL_PREFIX"
     do-upload 1m 8 --http2

Modified: httpd/test/mod_h2/trunk/test/test_trailer.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_trailer.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_trailer.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_trailer.sh Mon May 29 09:03:50 2017
@@ -24,6 +24,8 @@ echo "test trailers: $@"
 
 URL_PREFIX="$1"
 
+test_gen_data
+
 if min_httpd_version 2.4.18; then
     # basic test if we survive trailers via HTTP/2 at all
     # single
@@ -54,4 +56,4 @@ EOF
     # at the request *after* the content is read
 else
     echo "trailer tests require httpd >= 2.4.18"
-fi
\ No newline at end of file
+fi

Modified: httpd/test/mod_h2/trunk/test/test_window_update.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_window_update.sh?rev=1796599&r1=1796598&r2=1796599&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_window_update.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_window_update.sh Mon May 29 09:03:50 2017
@@ -23,12 +23,7 @@ echo "test window updates: $1"
 
 URL_PREFIX="$1"
 
-if [ ! -f $GEN/data-10k ]; then
-    i=0; while [ $i -lt 10 ]; do
-        cat $GEN/data-1k
-        i=$[ i + 1 ]
-    done  > $GEN/data-10k
-fi
+test_gen_data
 
 
 # test if small uploads trigger window_udpate(s) and do not let connection