mirror of
https://github.com/loewexy/pdnsmanager.git
synced 2025-01-16 03:02:22 +01:00
Fixed error in test if password is empty
This commit is contained in:
parent
8c7fbf40ef
commit
e39bb6d13c
3 changed files with 13 additions and 2 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -7,3 +7,4 @@ backend/src/config/ConfigUser.php
|
||||||
backend/src/config/ConfigOverride.php
|
backend/src/config/ConfigOverride.php
|
||||||
backend/test/config.sh
|
backend/test/config.sh
|
||||||
backend/test/node_modules/
|
backend/test/node_modules/
|
||||||
|
backend/test/logfile.log
|
||||||
|
|
|
@ -60,7 +60,12 @@ then
|
||||||
makeConfig
|
makeConfig
|
||||||
|
|
||||||
echo "Preparing Database"
|
echo "Preparing Database"
|
||||||
|
if [ -z "$DBPASSWORD" ]
|
||||||
|
then
|
||||||
|
mysql "-h$DBHOST" "-u$DBUSER" "$DBNAME" < db.sql
|
||||||
|
else
|
||||||
mysql "-h$DBHOST" "-u$DBUSER" "-p$DBPASSWORD" "$DBNAME" < db.sql
|
mysql "-h$DBHOST" "-u$DBUSER" "-p$DBPASSWORD" "$DBNAME" < db.sql
|
||||||
|
fi
|
||||||
|
|
||||||
echo "Executing test"
|
echo "Executing test"
|
||||||
if ! node "tests/$2.js" "$TESTURL"
|
if ! node "tests/$2.js" "$TESTURL"
|
||||||
|
@ -89,7 +94,12 @@ then
|
||||||
|
|
||||||
echo -n $(basename $test .js) "..."
|
echo -n $(basename $test .js) "..."
|
||||||
|
|
||||||
|
if [ -z "$DBPASSWORD" ]
|
||||||
|
then
|
||||||
|
mysql "-h$DBHOST" "-u$DBUSER" "$DBNAME" < db.sql
|
||||||
|
else
|
||||||
mysql "-h$DBHOST" "-u$DBUSER" "-p$DBPASSWORD" "$DBNAME" < db.sql
|
mysql "-h$DBHOST" "-u$DBUSER" "-p$DBPASSWORD" "$DBNAME" < db.sql
|
||||||
|
fi
|
||||||
|
|
||||||
echo -n "..."
|
echo -n "..."
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue