1
0
mirror of https://github.com/Yubico/yubikey-ksm.git synced 2024-11-29 00:24:14 +01:00

add sqlite support to the travis tests

This commit is contained in:
Klas Lindfors 2013-11-08 13:01:17 +01:00
parent bb33451eda
commit 5255e0f2c9
2 changed files with 9 additions and 0 deletions

View File

@ -7,5 +7,6 @@ php:
env:
- DB=mysql
- DB=pgsql
- DB=sqlite
script:
- ./selftest.sh

View File

@ -16,6 +16,14 @@ elif [ "x$DB" = "xpgsql" ]; then
psql -U $dbuser ykksm < ykksm-db.sql
dbrun="psql -U $dbuser ykksm -c"
elif [ "x$DB" = "xsqlite" ]; then
dbuser=""
dbfile=`mktemp`
sqlite3 $dbfile < ykksm-db.sql
sed -i "s,^.*db_dsn.*$,\$db_dsn = \"sqlite:$dbfile\";," ykksm-config.php
dbrun="sqlite3 $dbfile"
else
echo "unknown DB $DB"
exit 1