File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,19 +5,15 @@ progdir=${0%/*}
55
66cd $progdir /.. # now at trunk/
77
8- pidfile=$( test/test-setup) # create a patched django for test purposes, and more
9- [ " $pidfile " ] || die " Didn't get a pidfile name"
8+ test/test-setup # create a patched django for test purposes, and more
109
1110test/run-pyflakes ietf
1211
1312# Trap keyboard interrupt to ensure the test/teardown is run if we interrupt the tests
1413trap ' echo "$program($LINENO): Caught Interrupt"' INT
1514
1615# run tests with our patched django
17- PYTHONPATH=test:test/lib URLPREFIX=" $* " python ietf/manage.py test &
18- pid=$!
19- echo $pid > $pidfile
20- wait $pid
16+ PYTHONPATH=test:test/lib URLPREFIX=" $* " python ietf/manage.py test
2117
2218# reset keyboard interrupt trap
2319trap INT
Original file line number Diff line number Diff line change @@ -66,17 +66,18 @@ while true; do
6666 echo " $$ " > $PIDFILE
6767 chmod a+rwx $LOCKDIR
6868 chmod a+rw $PIDFILE
69- echo $PIDFILE # tell caller about the pidfile
7069 break
7170 else
7271 pid=$( < $PIDFILE )
7372 [ " $pid " ] || die " Couldn't read pidfile '$PIDFILE '"
7473 if kill -0 $pid ; then
75- say " Pidfile for process $pid exists, and process is running. Sleeping."
74+ echo " Pidfile for process $pid exists, and process is running. Sleeping."
7675 sleep 10
7776 else
78- say " Pidfile for process $pid exists, but process doesn't seem to be running."
79- die " Remove lockdir $LOCKDIR and old pid file $pidfile ."
77+ echo " Pidfile for process $pid exists, but process isn't running."
78+ echo " Removing lock and old pid file $pidfile ."
79+ rm -rf $LOCKDIR
80+ break
8081 fi
8182 fi
8283done
You can’t perform that action at this time.
0 commit comments