mirror of
https://github.com/fluencelabs/marine-rs-sdk-test
synced 2024-12-04 15:20:18 +00:00
ci: Prepare for E2E (#35)
This commit is contained in:
parent
047b7db722
commit
83927b78cb
2
.cargo/config.toml
Normal file
2
.cargo/config.toml
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
[registries]
|
||||||
|
fluence = { index = "git://crates.fluence.dev/index" }
|
19
.github/workflows/e2e.yml
vendored
Normal file
19
.github/workflows/e2e.yml
vendored
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
name: "e2e"
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
paths-ignore:
|
||||||
|
- "**.md"
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- "master"
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: "${{ github.workflow }}-${{ github.ref }}"
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
marine-rs-sdk-test:
|
||||||
|
uses: ./.github/workflows/tests.yml
|
||||||
|
with:
|
||||||
|
ref: ${{ github.ref }}
|
45
.github/workflows/marine-rs-sdk-test.yml
vendored
45
.github/workflows/marine-rs-sdk-test.yml
vendored
@ -1,45 +0,0 @@
|
|||||||
name: "marine-rs-sdk-test"
|
|
||||||
|
|
||||||
on:
|
|
||||||
pull_request:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- "master"
|
|
||||||
|
|
||||||
concurrency:
|
|
||||||
group: "${{ github.workflow }}-${{ github.ref }}"
|
|
||||||
cancel-in-progress: true
|
|
||||||
|
|
||||||
env:
|
|
||||||
RUST_TEST_THREADS: 1
|
|
||||||
CARGO_HOME: "${{ github.workspace }}/cargo"
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
marine-rs-sdk-test:
|
|
||||||
name: "Run tests"
|
|
||||||
runs-on: builder
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
|
|
||||||
- name: Setup rust toolchain
|
|
||||||
uses: actions-rust-lang/setup-rust-toolchain@v1
|
|
||||||
|
|
||||||
- name: Run cargo fmt
|
|
||||||
run: cargo fmt --all -- --check
|
|
||||||
|
|
||||||
- name: Run cargo build
|
|
||||||
run: cargo build
|
|
||||||
|
|
||||||
- name: Run cargo check
|
|
||||||
run: cargo check -v --all-features
|
|
||||||
|
|
||||||
- name: Run cargo test in marine-test-macro-impl
|
|
||||||
run: cargo test
|
|
||||||
working-directory: crates/marine-test-macro-impl
|
|
||||||
|
|
||||||
- name: Run cargo test
|
|
||||||
run: cargo test --release --all-features --no-fail-fast
|
|
||||||
|
|
||||||
- name: Run cargo clippy
|
|
||||||
run: cargo clippy -Z unstable-options --all
|
|
51
.github/workflows/tests.yml
vendored
Normal file
51
.github/workflows/tests.yml
vendored
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
name: Run tests with workflow_call
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_call:
|
||||||
|
inputs:
|
||||||
|
cargo-dependencies:
|
||||||
|
description: "Cargo dependencies map"
|
||||||
|
type: string
|
||||||
|
ref:
|
||||||
|
description: "git ref to checkout to"
|
||||||
|
type: string
|
||||||
|
default: "matster"
|
||||||
|
|
||||||
|
env:
|
||||||
|
RUST_TEST_THREADS: 1
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
marine-rs-sdk-test:
|
||||||
|
name: "Run tests"
|
||||||
|
runs-on: builder
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout to marine-rs-sdk-test
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
repository: "fluencelabs/marine-rs-sdk-test"
|
||||||
|
ref: ${{ inputs.ref }}
|
||||||
|
|
||||||
|
- name: Setup rust toolchain
|
||||||
|
uses: actions-rust-lang/setup-rust-toolchain@v1
|
||||||
|
|
||||||
|
- name: Set dependencies
|
||||||
|
if: inputs.cargo-dependencies != ''
|
||||||
|
uses: fluencelabs/github-actions/cargo-set-dependency@main
|
||||||
|
with:
|
||||||
|
dependencies: ${{ inputs.cargo-dependencies }}
|
||||||
|
|
||||||
|
- name: Run cargo build
|
||||||
|
run: cargo build
|
||||||
|
|
||||||
|
- name: Run cargo check
|
||||||
|
run: cargo check -v --all-features
|
||||||
|
|
||||||
|
- name: Run cargo test
|
||||||
|
run: cargo test --release --all-features --no-fail-fast
|
||||||
|
|
||||||
|
- name: Run cargo clippy
|
||||||
|
run: cargo clippy -Z unstable-options --all
|
||||||
|
|
||||||
|
- name: Run rustfmt
|
||||||
|
uses: actions-rust-lang/rustfmt@v1
|
@ -1,3 +1,4 @@
|
|||||||
[toolchain]
|
[toolchain]
|
||||||
channel = "nightly-2022-08-30"
|
channel = "nightly-2022-08-30"
|
||||||
targets = [ "x86_64-unknown-linux-gnu", "x86_64-apple-darwin", "wasm32-wasi" ]
|
targets = [ "x86_64-unknown-linux-gnu", "x86_64-apple-darwin", "wasm32-wasi" ]
|
||||||
|
components = ["clippy", "rustfmt"]
|
||||||
|
Loading…
Reference in New Issue
Block a user