Skip to content

升级 axum 及相关依赖到最新版本 #189

升级 axum 及相关依赖到最新版本

升级 axum 及相关依赖到最新版本 #189

Workflow file for this run

name: Test
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
env:
CARGO_TERM_COLOR: always
jobs:
test:
runs-on: ubuntu-latest
env:
SECRET_KEY: fake-key
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
mysql:
image: mysql
env:
MYSQL_ROOT_PASSWORD: mysqlpassword
MYSQL_DATABASE: testdb
options: >-
--health-cmd "mysqladmin ping"
--health-interval 10s
--health-timeout 5s
--health-retries 3
ports:
- 3306:3306
steps:
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Test Sqlite
env:
DATABASE_URL: sqlite:db.sqlite3?mode=rwc
run: |
cargo run -- init
cargo test --verbose
- name: Test Postgresql
env:
DATABASE_URL: postgres://postgres:postgres@localhost/postgres
run: |
cargo run -- init
cargo test --verbose
- name: Test Mysql
env:
DATABASE_URL: mysql://root:mysqlpassword@localhost/testdb
run: |
cargo run -- init
cargo test --verbose