Skip to content

feat: Identity creation #66

feat: Identity creation

feat: Identity creation #66

Workflow file for this run

name: Test
on:
push:
branches:
- main
pull_request:
env:
# When getting Rust dependencies, retry on network error:
CARGO_NET_RETRY: 10
# Use the local .curlrc
CURL_HOME: .
# Disable DFX telemetry
DFX_TELEMETRY: 'off'
jobs:
discover:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v4
- id: set-matrix
run: echo "matrix=$(python3 .github/scripts/test-matrix.py)" >> $GITHUB_OUTPUT
test:
name: ${{ matrix.test }} on ${{ matrix.os }}
needs: discover
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix: ${{fromJson(needs.discover.outputs.matrix)}}
steps:
- uses: actions/checkout@v4
- name: Show Rust toolchain version
run: rustup show
- uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ matrix.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}-test-1
- name: Install dfx
uses: dfinity/setup-dfx@main
- name: Set up path to dfx for tests and to pocketic for icp
run: |
dfx cache install
echo "ICPTEST_DFX_PATH=$(dfx cache show)/dfx" >> "$GITHUB_ENV"
echo "ICP_POCKET_IC_PATH=$(dfx cache show)/pocket-ic" >> "$GITHUB_ENV"
- name: Run ${{ matrix.test }}
run: cargo test --test ${{ matrix.test }}
aggregate:
name: test:required
if: ${{ always() }}
runs-on: ubuntu-latest
needs: [test]
steps:
- name: check result
if: ${{ needs.test.result != 'success' }}
run: exit 1