-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathjprove
More file actions
executable file
·25 lines (22 loc) · 923 Bytes
/
jprove
File metadata and controls
executable file
·25 lines (22 loc) · 923 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/bash
#
# jprove - Test Harness for PerlOnJava (Unix wrapper)
# Runs the standard prove script with jperl
#
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# Find prove script - check development path first, then installed path
if [ -f "$SCRIPT_DIR/src/main/perl/bin/prove" ]; then
PROVE_SCRIPT="$SCRIPT_DIR/src/main/perl/bin/prove"
elif [ -f "$SCRIPT_DIR/bin/prove" ]; then
PROVE_SCRIPT="$SCRIPT_DIR/bin/prove"
else
echo "Error: prove script not found" >&2
exit 1
fi
# Enable the orphan-exit watchdog in every jperl this run spawns. If the
# parent jprove process is killed (e.g. SIGKILL'd by the user, or
# terminated by a CI step), each child JVM polls its initial parent PID
# every 2s and self-exits when that parent disappears. See the matching
# block in `./jcpan` and AGENTS.md for the full rationale.
export JPERL_ORPHAN_EXIT=1
exec "$SCRIPT_DIR/jperl" "$PROVE_SCRIPT" "$@"