Ryan Brown | 50b473a | 2014-09-23 14:23:00 -0700 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
| 3 | # Helper script for testing two binaries under the same agent. |
| 4 | |
Jiri Simsa | f8727f2 | 2014-09-24 19:08:49 -0700 | [diff] [blame] | 5 | source "${VEYRON_ROOT}/scripts/lib/shell_test.sh" |
Ryan Brown | 50b473a | 2014-09-23 14:23:00 -0700 | [diff] [blame] | 6 | |
| 7 | main() { |
Asim Shankar | b3a82ba | 2014-10-29 11:41:27 -0700 | [diff] [blame] | 8 | if [[ -n "${VEYRON_CREDENTIALS}" ]]; then |
Ryan Brown | 50b473a | 2014-09-23 14:23:00 -0700 | [diff] [blame] | 9 | shell_test::fail "line ${LINENO}: identity preserved" |
| 10 | fi |
Jing Jin | 84a1152 | 2014-10-28 14:16:28 -0700 | [diff] [blame] | 11 | PINGPONG_BIN="$(shell_test::build_go_binary 'veyron.io/veyron/veyron/security/agent/pingpong')" |
Jing Jin | 89312ff | 2014-10-24 10:42:08 -0700 | [diff] [blame] | 12 | shell_test::start_server "${PINGPONG_BIN}" --server |
| 13 | "${PINGPONG_BIN}" || shell_test::fail "line ${LINENO}: ping" |
Ryan Brown | 50b473a | 2014-09-23 14:23:00 -0700 | [diff] [blame] | 14 | |
| 15 | shell_test::pass |
| 16 | } |
| 17 | |
| 18 | main "$@" |