teloxide/.github/workflows/ci.yml

53 lines
1.2 KiB
YAML
Raw Normal View History

on: [push, pull_request]
2019-11-27 17:30:33 +03:00
name: Continuous integration
jobs:
2020-07-01 21:15:48 +06:00
ci:
2020-07-01 21:13:53 +06:00
services:
redis:
image: redis
ports:
- 6379/tcp
2019-11-27 17:30:33 +03:00
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- stable
- beta
- nightly
steps:
- uses: actions/checkout@v1
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
2020-07-01 21:13:53 +06:00
components: rustfmt, clippyz
2019-11-27 17:30:33 +03:00
- name: stable/beta test
uses: actions-rs/cargo@v1
if: matrix.rust == 'stable' || matrix.rust == 'beta'
with:
command: test
2020-07-01 21:01:14 +06:00
args: --verbose --all-features
2019-11-27 17:30:33 +03:00
- name: stable/beta clippy
uses: actions-rs/cargo@v1
if: matrix.rust == 'stable' || matrix.rust == 'beta'
with:
command: clippy
2020-07-01 21:01:14 +06:00
args: --all-targets --all-features -- -D warnings
2019-11-27 17:30:33 +03:00
2020-03-31 13:38:48 +06:00
- name: Test the examples
2020-03-31 21:45:22 +06:00
run: cd examples && bash test_examples.sh
2020-03-31 13:38:48 +06:00
2020-03-27 18:54:06 +06:00
- name: fmt
uses: actions-rs/cargo@v1
if: matrix.rust == 'nightly'
with:
command: fmt
args: --all -- --check