Merge branch 'master' into ss/test_suite_refactor

# Conflicts:
#	.github/workflows/rust.yml
This commit is contained in:
Sam Samai 2021-08-05 21:49:41 +10:00
commit fbc26cd6dc

View File

@ -28,13 +28,7 @@ jobs:
toolchain: stable toolchain: stable
override: true override: true
- uses: actions/cache@v2 - uses: Swatinem/rust-cache@v1
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-test-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
- uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
with: with:
@ -50,108 +44,50 @@ jobs:
--all --all
--features default,runtime-${{ matrix.runtime }} --features default,runtime-${{ matrix.runtime }}
# sqlite: sqlite:
# name: SQLite name: SQLite
# runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
# strategy: strategy:
# matrix: matrix:
# # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls] # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls]
# runtime: [async-std-native-tls] runtime: [async-std-native-tls]
# steps: steps:
# - uses: actions/checkout@v2 - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1 - uses: actions-rs/toolchain@v1
# with: with:
# profile: minimal profile: minimal
# toolchain: stable toolchain: stable
# override: true override: true
# - uses: actions/cache@v2 - uses: Swatinem/rust-cache@v1
# with:
# path: |
# ~/.cargo/registry
# ~/.cargo/git
# target
# key: ${{ runner.os }}-sqlite-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
# - uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
# with: with:
# command: build command: build
# args: > args: >
# --all --all
# --features default,runtime-${{ matrix.runtime }} --features default,runtime-${{ matrix.runtime }}
# - uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
# with: with:
# command: test command: test
# args: > args: >
# --all --all
# --features default,sqlx-sqlite,runtime-${{ matrix.runtime }} --features default,sqlx-sqlite,runtime-${{ matrix.runtime }}
# postgres:
# name: Postgres
# runs-on: ubuntu-20.04
# strategy:
# matrix:
# # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls]
# runtime: [async-std-native-tls]
# services:
# postgres:
# image: postgres:11
# env:
# POSTGRES_HOST: 127.0.0.1
# POSTGRES_USER: root
# POSTGRES_PASSWORD: root
# ports:
# - "5432:5432"
# options: >-
# --health-cmd pg_isready
# --health-interval 10s
# --health-timeout 5s
# --health-retries 5
# steps:
# - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# toolchain: stable
# override: true
# - uses: actions/cache@v2
# with:
# path: |
# ~/.cargo/registry
# ~/.cargo/git
# target
# key: ${{ runner.os }}-postgres-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
# - uses: actions-rs/cargo@v1
# with:
# command: build
# args: >
# --all
# --features default,runtime-${{ matrix.runtime }}
# - uses: actions-rs/cargo@v1
# with:
# command: test
# args: >
# --all
# --features default,sqlx-postgres,runtime-${{ matrix.runtime }}
mysql: mysql:
name: MySQL name: MySQL
runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
strategy: strategy:
matrix: matrix:
# version: [8.0, 5.7, 5.6]
# runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls] # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls]
version: [8.0]
runtime: [async-std-native-tls] runtime: [async-std-native-tls]
env:
DATABASE_URL: mysql://root:@localhost
services: services:
mysql: mysql:
image: mysql:8.0 image: mysql:${{ matrix.version }}
env: env:
MYSQL_HOST: 127.0.0.1 MYSQL_HOST: 127.0.0.1
MYSQL_DB: mysql MYSQL_DB: mysql
@ -175,13 +111,7 @@ jobs:
toolchain: stable toolchain: stable
override: true override: true
- uses: actions/cache@v2 - uses: Swatinem/rust-cache@v1
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-mysql-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
- uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
with: with:
@ -197,57 +127,101 @@ jobs:
--all --all
--features default,sqlx-mysql,runtime-${{ matrix.runtime }} --features default,sqlx-mysql,runtime-${{ matrix.runtime }}
# mariadb: mariadb:
# name: MariaDB name: MariaDB
# runs-on: ubuntu-20.04 runs-on: ubuntu-20.04
# strategy: strategy:
# matrix: matrix:
# # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls] # version: [10.6, 10.5, 10.4, 10.3, 10.2]
# runtime: [async-std-native-tls] # runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls]
# services: version: [10.6]
# mysql: runtime: [async-std-native-tls]
# image: mariadb:10.5 services:
# env: mysql:
# MYSQL_HOST: 127.0.0.1 image: mariadb:${{ matrix.version }}
# MYSQL_DB: mysql env:
# MYSQL_USER: sea MYSQL_HOST: 127.0.0.1
# MYSQL_PASSWORD: sea MYSQL_DB: mysql
# MYSQL_ALLOW_EMPTY_PASSWORD: yes MYSQL_USER: sea
# MYSQL_ROOT_PASSWORD: MYSQL_PASSWORD: sea
# ports: MYSQL_ALLOW_EMPTY_PASSWORD: yes
# - "3306:3306" MYSQL_ROOT_PASSWORD:
# options: >- ports:
# --health-cmd="mysqladmin ping" - "3306:3306"
# --health-interval=10s options: >-
# --health-timeout=5s --health-cmd="mysqladmin ping"
# --health-retries=3 --health-interval=10s
# steps: --health-timeout=5s
# - uses: actions/checkout@v2 --health-retries=3
steps:
- uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1 - uses: actions-rs/toolchain@v1
# with: with:
# profile: minimal profile: minimal
# toolchain: stable toolchain: stable
# override: true override: true
# - uses: actions/cache@v2 - uses: Swatinem/rust-cache@v1
# with:
# path: |
# ~/.cargo/registry
# ~/.cargo/git
# target
# key: ${{ runner.os }}-mariadb-${{ matrix.runtime }}-${{ hashFiles('**/Cargo.lock') }}
# - uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
# with: with:
# command: build command: build
# args: > args: >
# --all --all
# --features default,runtime-${{ matrix.runtime }} --features default,runtime-${{ matrix.runtime }}
# - uses: actions-rs/cargo@v1 - uses: actions-rs/cargo@v1
# with: with:
# command: test command: test
# args: > args: >
# --all --all
# --features default,sqlx-mysql,runtime-${{ matrix.runtime }} --features default,sqlx-mysql,runtime-${{ matrix.runtime }}
postgres:
name: Postgres
runs-on: ubuntu-20.04
strategy:
matrix:
# version: [13.3, 12.7, 11.12, 10.17, 9.6.22]
# runtime: [async-std-native-tls, async-std-rustls, actix-native-tls, actix-rustls, tokio-native-tls, tokio-rustls]
version: [13.3]
runtime: [async-std-native-tls]
services:
postgres:
image: postgres:${{ matrix.version }}
env:
POSTGRES_HOST: 127.0.0.1
POSTGRES_USER: root
POSTGRES_PASSWORD: root
ports:
- "5432:5432"
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: Swatinem/rust-cache@v1
- uses: actions-rs/cargo@v1
with:
command: build
args: >
--all
--features default,runtime-${{ matrix.runtime }}
- uses: actions-rs/cargo@v1
with:
command: test
args: >
--all
--features default,sqlx-postgres,runtime-${{ matrix.runtime }}