mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-12-21 08:29:39 +08:00
Add pgtest script.
This commit is contained in:
parent
dd81eee222
commit
c1ae39a0cd
33
src/tools/pgtest
Executable file
33
src/tools/pgtest
Executable file
@ -0,0 +1,33 @@
|
||||
:
|
||||
|
||||
# This runs a build/initdb/regression test suite
|
||||
|
||||
[ ! "$PGDATA" ] && echo "You must define PGDATA" 1>&2 && exit 1
|
||||
|
||||
[ ! -d src ] && echo "This must be run from the top of the PostgreSQL source tree" 1>&2 && exit 1
|
||||
|
||||
trap "rm -rf /tmp/$$" 0 1 2 3 15
|
||||
mkdir /tmp/$$
|
||||
TMP="/tmp/$$"
|
||||
|
||||
pg_ctl stop
|
||||
rm -rf "$PGDATA"
|
||||
|
||||
cd src
|
||||
|
||||
# return command error value
|
||||
(gmake clean; gmake install 2>&1; echo "$?" > $TMP/ret) |
|
||||
(tee $TMP/0; exit `cat $TMP/ret`) &&
|
||||
initdb &&
|
||||
pg_ctl start &&
|
||||
createdb test &&
|
||||
cd src/test/regress &&
|
||||
gmake clean &&
|
||||
gmake installcheck
|
||||
|
||||
cat $TMP/0 |
|
||||
grep -v warning |
|
||||
grep -v setproctitle |
|
||||
grep -v find_rule |
|
||||
grep -v yy_flex_realloc |
|
||||
grep -v '\[javac\] [0-9]* warning'
|
Loading…
Reference in New Issue
Block a user