1257d72269d49fec6418c573ae70ac58e84c0185
[gnucomo.git] / test / t0011.sh
1 #!/bin/sh
2
3 #
4 #  Create an object 'vd.wt.tno.nl' in the database and
5 #  parse a piece of a apache access file which may be mistaken for an rpm list
6 #
7
8 LD_LIBRARY_PATH=/usr/local/pqxx/lib
9 export LD_LIBRARY_PATH
10
11 cd ..
12
13 if psql gnucomo_test -f src/database/create.sql -q >/dev/null
14 then
15    psql gnucomo_test -q -c "insert into object (objectname) values ('vd.wt.tno.nl')"
16    psql gnucomo_test -c "select * from object"
17    src/gcm_input/gcm_input -c gnucomo_test -h vd.wt.tno.nl -d 'nov 16 2003 20:30:45' <test/access_log
18    psql gnucomo_test -c "select * from log"
19    psql gnucomo_test -c "select * from parameter"
20    psql gnucomo_test -q -f src/database/destroy.sql
21    exit $result
22 else
23    echo Can not create test database
24    exit 1
25 fi