From a6198c50ee83e0a533198e02a0b67b7def15ec54 Mon Sep 17 00:00:00 2001 From: Cheng JIANG Date: Sun, 12 Apr 2020 10:44:57 +0200 Subject: [PATCH] add mysql sevice in CI --- .travis.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 980706d..e8df932 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,6 +7,7 @@ addons: - libssl-dev services: - postgresql + - mysql cache: cargo rust: - stable @@ -19,11 +20,15 @@ before_script: - rustup component add clippy - psql -c "CREATE DATABASE casbin;" -U postgres - psql -c "CREATE USER casbin_rs WITH PASSWORD 'casbin_rs';" -U postgres +- mysql -u root -e "CREATE DATABASE casbin;" +- mysql -u root -e "CREATE USER 'casbin_rs'@'localhost' IDENTIFIED BY 'casbin_rs'; GRANT ALL ON casbin.* TO 'casbin_rs'@'localhost';" script: - cargo clean -- cargo build -- cargo test +- cargo build --no-default-features --features postgres,runtime-async-std +- cargo test --no-default-features --features postgres,runtime-async-std +- cargo build --no-default-features --features mysql,runtime-async-std +- cargo test --no-default-features --features mysql,runtime-async-std - cargo clippy -- -D warnings - cargo fmt --all -- --check