httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ic...@apache.org
Subject svn commit: r1875781 - in /httpd/test/mod_h2/trunk/test: test_common.sh test_curl_get.sh test_frames.sh
Date Fri, 27 Mar 2020 14:45:59 GMT
Author: icing
Date: Fri Mar 27 14:45:58 2020
New Revision: 1875781

URL: http://svn.apache.org/viewvc?rev=1875781&view=rev
Log:
adapting to the HTML DOCTYPE changes

Modified:
    httpd/test/mod_h2/trunk/test/test_common.sh
    httpd/test/mod_h2/trunk/test/test_curl_get.sh
    httpd/test/mod_h2/trunk/test/test_frames.sh

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=1875781&r1=1875780&r2=1875781&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_common.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_common.sh Fri Mar 27 14:45:58 2020
@@ -74,8 +74,6 @@ CURL_VERSION=${CURL_VERSION%% *}
 OPENSSL_VERSION=$( $OPENSSL version )
 CURL_VERSIONS="$( $CURL -V )"
 
-HTML_DOCTYPE='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">'
-
 # so far, go gets its openssl linkage maybe from somewhere else
 
 min_version()
@@ -150,6 +148,17 @@ if min_httpd_version 2.4.19; then
     esac
 fi
 
+if min_httpd_version 2.5.0; then
+  HTML_DOCTYPE='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">'
+  HTML_DOCTYPE2=$HTML_DOCTYPE
+elif min_httpd_version 2.4.43; then
+  HTML_DOCTYPE='<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">'
+  HTML_DOCTYPE2='<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">'
+else
+  HTML_DOCTYPE='<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">'
+  HTML_DOCTYPE2=$HTML_DOCTYPE
+fi
+
 EXP_H2PUSH_CURL="$EXP_H2PUSH"
 if test -n "$EXP_H2PUSH"; then
     if min_curl_version 7.53.1; then

Modified: httpd/test/mod_h2/trunk/test/test_curl_get.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_curl_get.sh?rev=1875781&r1=1875780&r2=1875781&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_curl_get.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_curl_get.sh Fri Mar 27 14:45:58 2020
@@ -130,7 +130,7 @@ curl_check_necho 100000 "0123456789" $GE
 # github issue #126
 if min_httpd_version 2.4.26; then
 curl_check_content 006/ "autoindex w. include"    --http2 <<EOF
-$HTML_DOCTYPE
+$HTML_DOCTYPE2
 <html>
  <head>
   <title>Index of /006</title>

Modified: httpd/test/mod_h2/trunk/test/test_frames.sh
URL: http://svn.apache.org/viewvc/httpd/test/mod_h2/trunk/test/test_frames.sh?rev=1875781&r1=1875780&r2=1875781&view=diff
==============================================================================
--- httpd/test/mod_h2/trunk/test/test_frames.sh (original)
+++ httpd/test/mod_h2/trunk/test/test_frames.sh Fri Mar 27 14:45:58 2020
@@ -19,6 +19,9 @@ HTTPS_URL="$2"
 
 source $(dirname $0)/test_common.sh
 
+DT_LEN=$( echo -n $HTML_DOCTYPE | wc -c)
+ERR_LEN=$[ 146 + DT_LEN ]
+
 URL_PREFIX="$HTTP_URL"
 mh2fuzz_check_frames index.html "frames GET $URL_PREFIX" -f submit-delay100 <<EOF
 0: send SETTINGS[length=12, stream=0]
@@ -37,9 +40,9 @@ mh2fuzz_check_frames not-there "frames G
 0: send WINDOW_UPDATE[stream=0, inc=1073676288]
 0: send HEADERS[count=4, hend=1, stream=1, eos=1]
 0: recv HEADERS[count=0, hend=1, stream=1, eos=0]
-0: recv DATA[length=236, flags=0, stream=1, padlen=0]
+0: recv DATA[length=$ERR_LEN, flags=0, stream=1, padlen=0]
 0: recv DATA[length=0, flags=1, stream=1, padlen=0]
--->     0:00001 GET /not-there -> 404 236
+-->     0:00001 GET /not-there -> 404 $ERR_LEN
 0: send GOAWAY[error=0, last_stream=0, reason='']
 0/0/1/0/0 (2/3/4/5/0xx)
 EOF
@@ -67,9 +70,9 @@ ALPN: selected h2
 0: send WINDOW_UPDATE[stream=0, inc=1073676288]
 0: send HEADERS[count=4, hend=1, stream=1, eos=1]
 0: recv HEADERS[count=0, hend=1, stream=1, eos=0]
-0: recv DATA[length=236, flags=0, stream=1, padlen=0]
+0: recv DATA[length=$ERR_LEN, flags=0, stream=1, padlen=0]
 0: recv DATA[length=0, flags=1, stream=1, padlen=0]
--->     0:00001 GET /not-there -> 404 236
+-->     0:00001 GET /not-there -> 404 $ERR_LEN
 0: send GOAWAY[error=0, last_stream=0, reason='']
 0/0/1/0/0 (2/3/4/5/0xx)
 EOF



Mime
View raw message