]> arthur.barton.de Git - bup.git/blobdiff - t/test-web.sh
Split src tree python use to config/bin/python and dev/bup-python
[bup.git] / t / test-web.sh
index 1b34b8a947baa179fcdba1cab51a91b456058e3e..24a68a4109c97fc2a9701908d03f99831ec440fd 100755 (executable)
@@ -33,7 +33,7 @@ if test -z "$(type -p curl)"; then
     exit 0
 fi
     
-WVPASS bup-python -c "import socket as s; s.socket(s.AF_UNIX).bind('socket')"
+WVPASS bup-cfg-py -c "import socket as s; s.socket(s.AF_UNIX).bind('socket')"
 curl -s --unix-socket ./socket http://localhost/foo
 if test $? -ne 7; then
     WVSTART 'curl does not appear to support --unix-socket; skipping test'
@@ -49,6 +49,7 @@ WVSTART 'web'
 WVPASS bup init
 WVPASS mkdir src
 WVPASS echo '¡excitement!' > src/data
+WVPASS echo -e 'whee \x80\x90\xff' > "$(echo -ne 'src/whee \x80\x90\xff')"
 WVPASS bup index src
 WVPASS bup save -n '¡excitement!' --strip src
 
@@ -58,10 +59,13 @@ wait-for-server-start
 
 WVPASS curl --unix-socket ./socket \
        'http://localhost/%C2%A1excitement%21/latest/data' > result
+WVPASS curl --unix-socket ./socket \
+       'http://localhost/%C2%A1excitement%21/latest/whee%20%80%90%ff' > result2
 WVPASSEQ "$(curl --unix-socket ./socket http://localhost/static/styles.css)" \
          "$(cat "$TOP/lib/web/static/styles.css")"
 
 WVPASSEQ '¡excitement!' "$(cat result)"
+WVPASS cmp "$(echo -ne 'src/whee \x80\x90\xff')" result2
 WVPASS kill -s TERM "$web_pid"
 WVPASS wait "$web_pid"