Skip to content

bump agent-js

bump agent-js #658

Workflow file for this run

name: Backend
on:
push:
branches: [main]
pull_request:
paths:
- 'service/**'
- '.github/workflows/backend.yml'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
env:
DFX_VERSION: 0.15.2-beta.3
IC_REPL_VERSION: 0.6.0
MOC_VERSION: 0.10.2
steps:
- name: Setup Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
target: wasm32-unknown-unknown
- name: Cache cargo build
uses: actions/cache@v3
with:
path: |
~/.cargo/registry
~/.cargo/git
service/wasm-utils/target
key: cargo-${{ hashFiles('**/Cargo.lock') }}
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dfx
uses: dfinity/setup-dfx@main
with:
dfx-version: ${{ env.DFX_VERSION }}
- name: Install dfx dependencies
run: |
wget https://github.com/chenyan2002/ic-repl/releases/download/$IC_REPL_VERSION/ic-repl-linux64
cp ./ic-repl-linux64 /usr/local/bin/ic-repl
chmod a+x /usr/local/bin/ic-repl
npm i -g ic-mops
dfx cache install
cd $(dfx cache show)
wget https://github.com/dfinity/motoko/releases/download/$MOC_VERSION/motoko-Linux-x86_64-$MOC_VERSION.tar.gz
tar zxvf motoko-Linux-x86_64-$MOC_VERSION.tar.gz
- name: Start dfx
run: |
dfx start --background
- name: Checkout base branch
if: github.event_name == 'pull_request' && !contains(github.event.pull_request.labels.*.name, 'breaking_changes')
uses: actions/checkout@v3
with:
ref: ${{ github.base_ref }}
- name: Deploy main branch
if: github.event_name == 'pull_request' && !contains(github.event.pull_request.labels.*.name, 'breaking_changes')
run: |
dfx deploy backend
- uses: actions/checkout@v3
- name: Deploy current branch
run: dfx deploy backend
- name: CanisterPool test
run: |
(for f in service/pool/tests/*.test.sh; do
echo "==== Run test $f ===="
ic-repl "$f" || exit
done)
- name: Actor class test
run: |
cd ./service/pool/tests/actor_class
dfx canister create --all
dfx build
ic-repl ./test.sh
- name: Stop dfx
run: dfx stop