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:
parent
aa81bb8cd6
commit
6c95950515
4
.github/workflows/build_and_test.yml
vendored
4
.github/workflows/build_and_test.yml
vendored
@ -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 }}
|
||||
|
3
tests/aux/auth_mapping.sql
Normal file
3
tests/aux/auth_mapping.sql
Normal 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');
|
Loading…
Reference in New Issue
Block a user