Refresh CI scripts
This commit is contained in:
parent
445432f9ed
commit
a999f1fce4
8 changed files with 88 additions and 45 deletions
21
.github/codecov.yml
vendored
Normal file
21
.github/codecov.yml
vendored
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
# ref: https://docs.codecov.com/docs/codecovyml-reference
|
||||||
|
coverage:
|
||||||
|
# Hold ourselves to a high bar
|
||||||
|
range: 85..100
|
||||||
|
round: down
|
||||||
|
precision: 1
|
||||||
|
status:
|
||||||
|
# ref: https://docs.codecov.com/docs/commit-status
|
||||||
|
project:
|
||||||
|
default:
|
||||||
|
# Avoid false negatives
|
||||||
|
threshold: 1%
|
||||||
|
|
||||||
|
# Test files aren't important for coverage
|
||||||
|
ignore:
|
||||||
|
- "tests"
|
||||||
|
|
||||||
|
# Make comments less noisy
|
||||||
|
comment:
|
||||||
|
layout: "files"
|
||||||
|
require_changes: yes
|
||||||
20
.github/workflows/coverage.yml
vendored
20
.github/workflows/coverage.yml
vendored
|
|
@ -1,19 +1,25 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: coverage
|
name: coverage
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
|
||||||
image: xd009642/tarpaulin
|
|
||||||
options: --security-opt seccomp=unconfined
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
|
- uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
profile: minimal
|
||||||
|
toolchain: stable
|
||||||
|
override: true
|
||||||
|
components: llvm-tools-preview
|
||||||
|
- name: Install cargo-llvm-cov
|
||||||
|
uses: taiki-e/install-action@cargo-llvm-cov
|
||||||
- name: Generate code coverage
|
- name: Generate code coverage
|
||||||
run: |
|
run: cargo llvm-cov --all-features --lcov --output-path lcov.info
|
||||||
cargo tarpaulin --verbose --timeout 120 --out Xml
|
|
||||||
env:
|
env:
|
||||||
TEST_HOST: greenmail
|
TEST_HOST: greenmail
|
||||||
- name: Upload to codecov.io
|
- name: Upload to codecov.io
|
||||||
|
|
|
||||||
12
.github/workflows/features.yml
vendored
12
.github/workflows/features.yml
vendored
|
|
@ -1,6 +1,6 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: cargo hack
|
name: cargo hack
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -11,13 +11,11 @@ jobs:
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: stable
|
toolchain: stable
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Install cargo-hack
|
|
||||||
uses: actions-rs/install@v0.1
|
|
||||||
with:
|
with:
|
||||||
crate: cargo-hack
|
submodules: true
|
||||||
version: latest
|
- name: Install cargo-hack
|
||||||
use-tool-cache: true
|
uses: taiki-e/install-action@cargo-hack
|
||||||
- name: cargo hack
|
- name: cargo hack
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
|
|
|
||||||
23
.github/workflows/minimal.yml
vendored
23
.github/workflows/minimal.yml
vendored
|
|
@ -1,6 +1,6 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: With dependencies at minimal versions
|
name: With dependencies at minimal versions
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -15,7 +15,9 @@ jobs:
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: stable
|
toolchain: stable
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
- name: cargo update -Zminimal-versions
|
- name: cargo update -Zminimal-versions
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
|
|
@ -26,15 +28,12 @@ jobs:
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
command: test
|
command: test
|
||||||
|
args: --features test-full-imap --all-targets
|
||||||
services:
|
services:
|
||||||
greenmail:
|
cyrus_imapd:
|
||||||
image: greenmail/standalone:1.6.8
|
image: outoforder/cyrus-imapd-tester:latest
|
||||||
ports:
|
ports:
|
||||||
- 3025:3025
|
- 3025:25
|
||||||
- 3110:3110
|
- 3143:143
|
||||||
- 3143:3143
|
- 3465:465
|
||||||
- 3465:3465
|
- 3993:993
|
||||||
- 3993:3993
|
|
||||||
- 3995:3995
|
|
||||||
env:
|
|
||||||
GREENMAIL_OPTS: "-Dgreenmail.setup.test.all -Dgreenmail.hostname=0.0.0.0 -Dgreenmail.auth.disabled -Dgreenmail.verbose"
|
|
||||||
|
|
|
||||||
10
.github/workflows/msrv.yml
vendored
10
.github/workflows/msrv.yml
vendored
|
|
@ -1,6 +1,6 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: Minimum Supported Rust Version
|
name: Minimum Supported Rust Version
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -10,10 +10,12 @@ jobs:
|
||||||
- uses: actions-rs/toolchain@v1
|
- uses: actions-rs/toolchain@v1
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: 1.56.0 # 2021 edition requires 1.56
|
toolchain: 1.56.1 # 2021 edition requires 1.56
|
||||||
override: true
|
override: true
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: cargo +1.56.0 check
|
with:
|
||||||
|
submodules: true
|
||||||
|
- name: cargo +1.56.1 check
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
command: check
|
command: check
|
||||||
|
|
|
||||||
6
.github/workflows/os-check.yml
vendored
6
.github/workflows/os-check.yml
vendored
|
|
@ -1,8 +1,8 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: cargo check
|
name: os check
|
||||||
jobs:
|
jobs:
|
||||||
os-check:
|
os-check:
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
|
|
@ -16,7 +16,7 @@ jobs:
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: stable
|
toolchain: stable
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: cargo check
|
- name: cargo check
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
|
|
|
||||||
28
.github/workflows/style.yml
vendored
28
.github/workflows/style.yml
vendored
|
|
@ -1,6 +1,6 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: lint
|
name: lint
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -17,20 +17,32 @@ jobs:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: ${{ matrix.toolchain }}
|
toolchain: ${{ matrix.toolchain }}
|
||||||
components: rustfmt, clippy
|
components: rustfmt, clippy
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
- name: cargo fmt --check
|
- name: cargo fmt --check
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
command: fmt
|
command: fmt
|
||||||
args: --check
|
args: --check
|
||||||
- name: cargo doc
|
|
||||||
uses: actions-rs/cargo@v1
|
|
||||||
if: always()
|
|
||||||
with:
|
|
||||||
command: doc
|
|
||||||
args: --no-deps --all-features
|
|
||||||
- name: cargo clippy
|
- name: cargo clippy
|
||||||
uses: actions-rs/clippy-check@v1
|
uses: actions-rs/clippy-check@v1
|
||||||
if: always()
|
if: always()
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
doc:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
profile: minimal
|
||||||
|
toolchain: nightly
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: cargo doc
|
||||||
|
uses: actions-rs/cargo@v1
|
||||||
|
with:
|
||||||
|
toolchain: nightly
|
||||||
|
command: doc
|
||||||
|
args: --no-deps --all-features
|
||||||
|
env:
|
||||||
|
RUSTDOCFLAGS: --cfg docsrs
|
||||||
|
|
|
||||||
13
.github/workflows/test.yml
vendored
13
.github/workflows/test.yml
vendored
|
|
@ -1,6 +1,6 @@
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [main]
|
||||||
pull_request:
|
pull_request:
|
||||||
name: cargo test
|
name: cargo test
|
||||||
jobs:
|
jobs:
|
||||||
|
|
@ -15,11 +15,14 @@ jobs:
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: ${{ matrix.toolchain }}
|
toolchain: ${{ matrix.toolchain }}
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
- name: cargo test
|
- name: cargo test
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
command: test
|
command: test
|
||||||
|
args: --all-targets
|
||||||
services:
|
services:
|
||||||
greenmail:
|
greenmail:
|
||||||
image: greenmail/standalone:1.6.8
|
image: greenmail/standalone:1.6.8
|
||||||
|
|
@ -43,12 +46,14 @@ jobs:
|
||||||
with:
|
with:
|
||||||
profile: minimal
|
profile: minimal
|
||||||
toolchain: ${{ matrix.toolchain }}
|
toolchain: ${{ matrix.toolchain }}
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
submodules: true
|
||||||
- name: cargo test
|
- name: cargo test
|
||||||
uses: actions-rs/cargo@v1
|
uses: actions-rs/cargo@v1
|
||||||
with:
|
with:
|
||||||
command: test
|
command: test
|
||||||
args: --features test-full-imap
|
args: --features test-full-imap --all-targets
|
||||||
services:
|
services:
|
||||||
cyrus_imapd:
|
cyrus_imapd:
|
||||||
image: outoforder/cyrus-imapd-tester:latest
|
image: outoforder/cyrus-imapd-tester:latest
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue