Migrate CI workflows to CircleCI #1384
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Integration | |
on: | |
push: | |
branches: | |
- main | |
- dev | |
pull_request: | |
jobs: | |
test-linux: | |
name: JS Ad4mClient <> AD4M Executor - Linux | |
strategy: | |
matrix: | |
platform: [GH-hosted-ubuntu] | |
node-version: [16.x] | |
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/ | |
runs-on: ${{ matrix.platform }} | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: 1.73.0 | |
- name: Install GO | |
uses: actions/setup-go@v4 | |
with: | |
go-version: '1.20' | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8 | |
- name: Cache cargo | |
id: cache-cargo | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
target/ | |
key: ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
restore-keys: | | |
${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
${{ runner.os }}-cargo | |
- run: rustup target add wasm32-unknown-unknown | |
- name: Install Deno | |
uses: denoland/setup-deno@v1 | |
with: | |
deno-version: v1.32.4 | |
- name: install system dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf protobuf-compiler cmake | |
- name: Install HC | |
run: cargo install holochain_cli --version 0.3.0-beta-dev.27 || echo "hc already installed" | |
- name: Install dependencies | |
run: pnpm install --no-frozen-lockfile | |
- name: Build the workspace | |
run: pnpm run build | |
- uses: actions/cache/save@v3 | |
if: always() | |
with: | |
path: | | |
~/.cargo/bin/ | |
~/.cargo/registry/index/ | |
~/.cargo/registry/cache/ | |
~/.cargo/git/db/ | |
target/ | |
key: ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
- name: Run the tests | |
run: pnpm test | |
- name: Run integration tests | |
run: cd ./tests/js && pnpm run test-main | |
# test-windows: | |
# name: JS Ad4mClient <> AD4M Executor - Windows | |
# runs-on: windows-2019 | |
# strategy: | |
# matrix: | |
# node-version: [16.x] | |
# steps: | |
# - uses: actions/checkout@v2 | |
# - uses: actions-rs/toolchain@v1 | |
# with: | |
# toolchain: 1.68.2 | |
# - name: Cache cargo | |
# id: cache-cargo | |
# uses: actions/cache@v3 | |
# with: | |
# path: | | |
# ~/.cargo/bin/ | |
# ~/.cargo/registry/index/ | |
# ~/.cargo/registry/cache/ | |
# ~/.cargo/git/db/ | |
# target/ | |
# key: ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# restore-keys: | | |
# ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# ${{ runner.os }}-cargo | |
# - run: rustup target add wasm32-unknown-unknown | |
# - name: Use Node.js ${{ matrix.node-version }} | |
# uses: actions/setup-node@v2 | |
# with: | |
# node-version: ${{ matrix.node-version }} | |
# - name: Install Deno | |
# uses: denoland/setup-deno@v1 | |
# with: | |
# deno-version: v1.32.4 | |
# - name: Install dependencies | |
# run: pnpm install | |
# - name: Build the workspace | |
# run: pnpm run build | |
# - uses: actions/cache/save@v3 | |
# if: always() | |
# with: | |
# path: | | |
# ~/.cargo/bin/ | |
# ~/.cargo/registry/index/ | |
# ~/.cargo/registry/cache/ | |
# ~/.cargo/git/db/ | |
# target/ | |
# key: $${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# - name: Run the tests | |
# run: | | |
# choco install swi-prolog | |
# $env:path += ";C:\Program Files\swipl\bin" | |
# pnpm run test:windows | |
# test-macos: | |
# name: JS Ad4mClient <> AD4M Executor - MacOS | |
# runs-on: macos-latest | |
# strategy: | |
# matrix: | |
# node-version: [16.x] | |
# steps: | |
# - uses: actions/checkout@v3 | |
# - uses: actions-rs/toolchain@v1 | |
# with: | |
# toolchain: 1.68.2 | |
# - name: Use Node.js ${{ matrix.node-version }} | |
# uses: actions/setup-node@v2 | |
# with: | |
# node-version: ${{ matrix.node-version }} | |
# - name: Cache cargo | |
# id: cache-cargo | |
# uses: actions/cache@v3 | |
# with: | |
# path: | | |
# ~/.cargo/bin/ | |
# ~/.cargo/registry/index/ | |
# ~/.cargo/registry/cache/ | |
# ~/.cargo/git/db/ | |
# target/ | |
# key: ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# restore-keys: | | |
# ${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# ${{ runner.os }}-cargo | |
# - run: rustup target add wasm32-unknown-unknown | |
# - name: Install Deno | |
# uses: denoland/setup-deno@v1 | |
# with: | |
# deno-version: v1.32.4 | |
# - name: Install dependencies | |
# run: pnpm install | |
# - name: Build the workspace | |
# run: pnpm run build | |
# - uses: actions/cache/save@v3 | |
# if: always() | |
# with: | |
# path: | | |
# ~/.cargo/bin/ | |
# ~/.cargo/registry/index/ | |
# ~/.cargo/registry/cache/ | |
# ~/.cargo/git/db/ | |
# target/ | |
# key: $${{ runner.os }}-cargo-${{ hashFiles('./Cargo.lock') }} | |
# - name: Run the tests | |
# run: pnpm test |