Skip to content
Permalink
Browse files

integration tests: remove python dependency (#1145)

Motivation:

The integration tests depended on python in order to print 80,000 x
characters.

Modifications:

Remove the python dependency and express the same with `dd` & `tr`.

Result:

Fewer dependencies.
  • Loading branch information...
weissi committed Sep 24, 2019
1 parent 43413ce commit 7767c4f6af6e158e11d89e8670a460722f09767b
Showing with 2 additions and 2 deletions.
  1. +2 −2 IntegrationTests/tests_01_http/test_12_headers_too_large.sh
@@ -28,12 +28,12 @@ $cr
EOF
echo "FOO BAR" > "$htdocs/some_file.txt"
# headers have acceptable size
do_curl "$token" -H "$(python -c 'print "x"*80000'): x" \
do_curl "$token" -H "$(dd if=/dev/zero bs=1000 count=80 2> /dev/null | tr '\0' x): x" \
"http://foobar.com/fileio/some_file.txt" > "$tmp/out"
assert_equal_files "$htdocs/some_file.txt" "$tmp/out"

# headers too large
do_curl "$token" -H "$(python -c 'print "x"*90000'): x" \
do_curl "$token" -H "$(dd if=/dev/zero bs=1000 count=90 2> /dev/null | tr '\0' x): x" \
-D "$tmp/headers_actual" \
"http://foobar.com/fileio/some_file.txt" > "$tmp/out"
assert_equal_files "$tmp/empty" "$tmp/out"

0 comments on commit 7767c4f

Please sign in to comment.
You can’t perform that action at this time.