Skip to content

Commit

Permalink
ci: fix cargo test commands
Browse files Browse the repository at this point in the history
  • Loading branch information
FlorianFranzen committed Jul 3, 2024
1 parent cc0e6d5 commit f17f1cd
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .github/actions/cargo-command/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ inputs:
required: false
default: 'build'
package:
description: 'Limit execution to a specific package'
description: 'Limit execution to a specific package, assumes workspace if unset'
required: false
profile:
description: 'Profile under which to run cargo command'
Expand Down Expand Up @@ -52,4 +52,4 @@ runs:
env:
CARGO_TERM_COLOR: always
shell: bash
run: cargo ${{ inputs.command }} ${{ inputs.package != '' && '--package' || '' }} ${{ inputs.package }} --profile '${{ inputs.profile }}' --features '${{ inputs.features }}' --message-format json ${{ inputs.args }} | cargo-action-fmt
run: cargo ${{ inputs.command }} ${{ inputs.package == '' && '--workspace' || '--package' }} ${{ inputs.package }} --profile '${{ inputs.profile }}' --features '${{ inputs.features }}' --message-format json ${{ inputs.args }} | cargo-action-fmt
2 changes: 1 addition & 1 deletion .github/workflows/merge-pages-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
uses: ./.github/actions/cargo-command
with:
command: doc
args: --workspace --no-deps --document-private-items
args: --no-deps --document-private-items
- name: Assemble structure
env:
DOCS_HIDEOUT: an8ohgahmoot6ro8ieReib9micau0Oow
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr-build-docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
uses: ./.github/actions/cargo-command
with:
command: doc
args: --workspace --no-deps --document-private-items
args: --no-deps --document-private-items
- name: Upload docs
uses: actions/upload-artifact@v4
with:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/pr-build-runtime.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ jobs:
uses: ./.github/actions/cargo-command
with:
package: ${{ matrix.package }}
profile: release
features: ${{ matrix.features }}
- name: Upload timechain runtime
uses: actions/upload-artifact@v4
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/pr-test-cargo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,14 @@ jobs:
matrix:
include:
- command: clippy
args: --all-targets --workspace --examples --tests -- --no-deps -D warnings
- command: test
args: --workspace --locked
args: --all-targets --all-features --examples --tests -- --no-deps -D warnings
- command: check
features: runtime-benchmarks
- command: check
features: try-runtime
- command: test
args: --no-run
after: cargo test --workspace
steps:
- name: Checkout sources
uses: actions/checkout@v4
Expand All @@ -47,3 +48,6 @@ jobs:
command: ${{ matrix.command }}
features: ${{ matrix.features }}
args: ${{ matrix.args }}
- name: Run optional command
if: ${{ matrix.after != '' }}
run: ${{ matrix.after }}

0 comments on commit f17f1cd

Please sign in to comment.