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

sql: more setup for sql tests

This commit is contained in:
Klas Lindfors 2021-04-06 13:36:00 +02:00
parent aa81bb8cd6
commit 6c95950515
No known key found for this signature in database
GPG Key ID: BCA00FD4B2168C0A
2 changed files with 6 additions and 1 deletions

View File

@ -39,7 +39,7 @@ jobs:
env:
MYSQL_USER: user
MYSQL_PASSWORD: password
MYSQL_DATABASE: test
MYSQL_DATABASE: otp
MYSQL_ROOT_PASSWORD: password
options: --health-cmd="mysqladmin ping" --health-interval=5s --health-timeout=2s --health-retries=3
steps:
@ -52,6 +52,8 @@ jobs:
while ! mysqladmin ping -h"127.0.0.1" -P"$MYSQL_PORT" --silent; do
sleep 1
done
mysql --user=user --password=password --host=127.0.0.1 --port=$MYSQL_PORT otp < yubikey_mapping.sql
mysql --user=user --password=password --host=127.0.0.1 --port=$MYSQL_PORT otp < tests/aux/auth_mapping.sql
- name: Build and test
env:
CONFIGURE_ARGS: ${{ matrix.config_args }}

View File

@ -0,0 +1,3 @@
INSERT INTO yubikey_mappings (otp_id, username) VALUES ('vvincredible', 'foo');
INSERT INTO yubikey_mappings (otp_id, username) VALUES ('cccccccfhcbe', 'test');
INSERT INTO yubikey_mappings (otp_id, username) VALUES ('ccccccbchvth', 'test');