rsyslog/tests/pgsql-basic.sh
Dan Molik f334e2b250 ompgsql plugin - update postgres module
The PostgreSQL output module was woefully out-of-date the following
list is changes made to update the module to current Rsyslog standards.

  - allow for v6 configuration syntax
  - configurable ports
  - support transactional interface
  - push db connection into workers (libpq is threadsafe)
  - enable module testing on travis
  - ensure configuration syntax backwards compatibility
  - formatting around postgres core templating
  - use new test conventions
  - add new configuration syntax test
  - add valgrind tests for new and old syntax
  - add threading tests
  - add action queue long running tests
  - add action queue valgrind test
2017-12-09 09:04:46 -05:00

20 lines
579 B
Bash
Executable File

#!/bin/bash
# This file is part of the rsyslog project, released under GPLv3
. $srcdir/diag.sh init
psql -h localhost -U postgres -f testsuites/pgsql-basic.sql
. $srcdir/diag.sh startup pgsql-basic.conf
. $srcdir/diag.sh injectmsg 0 5000
. $srcdir/diag.sh shutdown-when-empty
. $srcdir/diag.sh wait-shutdown
psql -h localhost -U postgres -d syslogtest -f testsuites/pgsql-select-msg.sql -t -A > rsyslog.out.log
. $srcdir/diag.sh seq-check 0 4999
echo cleaning up test database
psql -h localhost -U postgres -c 'DROP DATABASE IF EXISTS syslogtest;'
. $srcdir/diag.sh exit