e2e-test: indentation cleanup, whitespace only
This commit is contained in:
+38
-38
@@ -71,7 +71,7 @@ tmux_check()
|
|||||||
version_minor=${version##*.}
|
version_minor=${version##*.}
|
||||||
# need version 1.8 for capture-pane
|
# need version 1.8 for capture-pane
|
||||||
if [ $version_major -lt 1 ] ||
|
if [ $version_major -lt 1 ] ||
|
||||||
[ $version_major -eq 1 -a $version_minor -lt 8 ]; then
|
[ $version_major -eq 1 -a $version_minor -lt 8 ]; then
|
||||||
error "tmux version %s too old\n" "$version"
|
error "tmux version %s too old\n" "$version"
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
@@ -200,44 +200,44 @@ for run in $server_tests; do
|
|||||||
export MOSH_CLIENT="$PWD/../frontend/mosh-client"
|
export MOSH_CLIENT="$PWD/../frontend/mosh-client"
|
||||||
export MOSH_SERVER="$PWD/../frontend/mosh-server"
|
export MOSH_SERVER="$PWD/../frontend/mosh-server"
|
||||||
export MOSH_E2E_TEST="$PWD/${test_dir}/${run}"
|
export MOSH_E2E_TEST="$PWD/${test_dir}/${run}"
|
||||||
# XXX need to quote special chars in server pathname here somehow
|
# XXX need to quote special chars in server pathname here somehow
|
||||||
sut="../../scripts/mosh --client=${srcdir}/mosh-client --server=${srcdir}/mosh-server --local --bind-server=127.0.0.1 127.0.0.1"
|
sut="../../scripts/mosh --client=${srcdir}/mosh-client --server=${srcdir}/mosh-server --local --bind-server=127.0.0.1 127.0.0.1"
|
||||||
testarg=$run
|
testarg=$run
|
||||||
if [ "$run" = "direct" ]; then
|
if [ "$run" = "direct" ]; then
|
||||||
sut=""
|
sut=""
|
||||||
fi
|
fi
|
||||||
# Actually execute code under test
|
# Actually execute code under test
|
||||||
# XXX tmux 1.8 requires shell command as a single arg; once we move to 2.0, undo these quotes
|
# XXX tmux 1.8 requires shell command as a single arg; once we move to 2.0, undo these quotes
|
||||||
# XXX this ignores $TMPDIR, because it results in an overlong pathname on OS X
|
# XXX this ignores $TMPDIR, because it results in an overlong pathname on OS X
|
||||||
tmux_socket="/tmp/.tmux-mosh-test-$$"
|
tmux_socket="/tmp/.tmux-mosh-test-$$"
|
||||||
${tmux_stdin} tmux -S "${tmux_socket}" -C new-session "${srcdir}/print-exitstatus ${client_wrapper} ${sut} \"${srcdir}/e2e-test-server\" \"${PWD}/${test_dir}/${run}\" \"${PWD}/${test_script} ${testarg}\"" > "${test_dir}/${run}.tmux.log"
|
${tmux_stdin} tmux -S "${tmux_socket}" -C new-session "${srcdir}/print-exitstatus ${client_wrapper} ${sut} \"${srcdir}/e2e-test-server\" \"${PWD}/${test_dir}/${run}\" \"${PWD}/${test_script} ${testarg}\"" > "${test_dir}/${run}.tmux.log"
|
||||||
rv=$?
|
rv=$?
|
||||||
rm -f "${tmux_socket}"
|
rm -f "${tmux_socket}"
|
||||||
if [ $rv -ne 0 ]; then
|
if [ $rv -ne 0 ]; then
|
||||||
test_error "tmux failure on test %s\n" "$run"
|
test_error "tmux failure on test %s\n" "$run"
|
||||||
fi
|
fi
|
||||||
# Check for mosh failures
|
# Check for mosh failures
|
||||||
if ! grep -q "%%% exitstatus: 0 %%%" "${test_dir}/${run}.tmux.log"; then
|
if ! grep -q "%%% exitstatus: 0 %%%" "${test_dir}/${run}.tmux.log"; then
|
||||||
test_error "mosh-client had non-zero exitstatus\n"
|
test_error "mosh-client had non-zero exitstatus\n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Check for server harness failures
|
# Check for server harness failures
|
||||||
if [ ! -s "${test_dir}/${run}.capture" ] \
|
if [ ! -s "${test_dir}/${run}.capture" ] \
|
||||||
|| [ ! -s "${test_dir}/${run}.exitstatus" ]; then
|
|| [ ! -s "${test_dir}/${run}.exitstatus" ]; then
|
||||||
test_error "server harness failure on test %s\n" "$run"
|
test_error "server harness failure on test %s\n" "$run"
|
||||||
fi
|
fi
|
||||||
read server_rv < "${test_dir}/${run}.exitstatus"
|
read server_rv < "${test_dir}/${run}.exitstatus"
|
||||||
if [ "$server_rv" -ne 0 ]; then
|
if [ "$server_rv" -ne 0 ]; then
|
||||||
test_error "server harness exited with status %s\n" "$server_rv"
|
test_error "server harness exited with status %s\n" "$server_rv"
|
||||||
fi
|
fi
|
||||||
# Check for "round-trip" failures
|
# Check for "round-trip" failures
|
||||||
if grep -q "round-trip Instruction verification failed" "${test_dir}/${run}.server.stderr"; then
|
if grep -q "round-trip Instruction verification failed" "${test_dir}/${run}.server.stderr"; then
|
||||||
test_error "Round-trip Instruction verification failed on server during %s\n" "$run"
|
test_error "Round-trip Instruction verification failed on server during %s\n" "$run"
|
||||||
fi
|
fi
|
||||||
# XXX We'd also like to check for "target state Instruction
|
# XXX We'd also like to check for "target state Instruction
|
||||||
# verification failed", a new check, but tmux's lack of BCE
|
# verification failed", a new check, but tmux's lack of BCE
|
||||||
# support forces mosh to clear lines with spaces and change a
|
# support forces mosh to clear lines with spaces and change a
|
||||||
# framebuffer in a way that causes this to fire spuriously.
|
# framebuffer in a way that causes this to fire spuriously.
|
||||||
done
|
done
|
||||||
|
|
||||||
for compare in $compare_tests; do
|
for compare in $compare_tests; do
|
||||||
|
|||||||
Reference in New Issue
Block a user