Files
openzeppelin-contracts/scripts/test.sh
2017-02-17 18:03:52 -03:00

14 lines
278 B
Bash
Executable File

#! /bin/bash
output=$(nc -z localhost 8545; echo $?)
[ $output -eq "0" ] && trpc_running=true
if [ ! $trpc_running ]; then
echo "Starting our own testrpc node instance"
testrpc > /dev/null &
trpc_pid=$!
fi
truffle test
if [ ! $trpc_running ]; then
kill -9 $trpc_pid
fi