Avoid getting gofail/runtime when failpoints are disabled
@@ -19,6 +19,7 @@ toggle_failpoints() {
mode="$1"
if command -v gofail >/dev/null 2>&1; then
run gofail "$mode" server/etcdserver/ server/storage/backend/ server/storage/mvcc/
+ if [[ "$mode" == "enable" ]]; then
(
cd ./server
run go get go.etcd.io/gofail/runtime
@@ -35,6 +36,7 @@ toggle_failpoints() {
cd ./tests
run go get go.etcd.io/gofail/runtime
) || exit 2
+ fi
elif [[ "$mode" != "disable" ]]; then
log_error "FAILPOINTS set but gofail not found"
exit 1
