mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-01-05 21:02:58 +00:00
Signed-off-by: Ruihang Xia <waynestxia@gmail.com> Signed-off-by: Ruihang Xia <waynestxia@gmail.com>
71 lines
1.9 KiB
YAML
71 lines
1.9 KiB
YAML
on:
|
|
pull_request:
|
|
types: [opened, synchronize, reopened, ready_for_review]
|
|
paths-ignore:
|
|
- 'docs/**'
|
|
- 'config/**'
|
|
- '**.md'
|
|
- '.dockerignore'
|
|
- 'docker/**'
|
|
- '.gitignore'
|
|
push:
|
|
branches:
|
|
- "main"
|
|
- "develop"
|
|
paths-ignore:
|
|
- 'docs/**'
|
|
- 'config/**'
|
|
- '**.md'
|
|
- '.dockerignore'
|
|
- 'docker/**'
|
|
- '.gitignore'
|
|
workflow_dispatch:
|
|
|
|
name: Code coverage
|
|
|
|
env:
|
|
RUST_TOOLCHAIN: nightly-2022-12-20
|
|
|
|
jobs:
|
|
coverage:
|
|
if: github.event.pull_request.draft == false
|
|
runs-on: ubuntu-latest-8-cores
|
|
timeout-minutes: 60
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- uses: arduino/setup-protoc@v1
|
|
with:
|
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
|
- uses: KyleMayes/install-llvm-action@v1
|
|
with:
|
|
version: "14.0"
|
|
- name: Install toolchain
|
|
uses: dtolnay/rust-toolchain@master
|
|
with:
|
|
toolchain: ${{ env.RUST_TOOLCHAIN }}
|
|
components: llvm-tools-preview
|
|
- name: Rust Cache
|
|
uses: Swatinem/rust-cache@v2
|
|
- name: Install latest nextest release
|
|
uses: taiki-e/install-action@nextest
|
|
- name: Install cargo-llvm-cov
|
|
uses: taiki-e/install-action@cargo-llvm-cov
|
|
- name: Collect coverage data
|
|
run: cargo llvm-cov nextest --workspace --lcov --output-path lcov.info
|
|
env:
|
|
CARGO_BUILD_RUSTFLAGS: "-C link-arg=-fuse-ld=lld"
|
|
RUST_BACKTRACE: 1
|
|
CARGO_INCREMENTAL: 0
|
|
GT_S3_BUCKET: ${{ secrets.S3_BUCKET }}
|
|
GT_S3_ACCESS_KEY_ID: ${{ secrets.S3_ACCESS_KEY_ID }}
|
|
GT_S3_ACCESS_KEY: ${{ secrets.S3_ACCESS_KEY }}
|
|
UNITTEST_LOG_DIR: "__unittest_logs"
|
|
- name: Codecov upload
|
|
uses: codecov/codecov-action@v2
|
|
with:
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
files: ./lcov.info
|
|
flags: rust
|
|
fail_ci_if_error: true
|
|
verbose: true
|