mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2024-11-29 05:18:11 +03:00
dc4b2ae554
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.5 to 2.1.6. - [Release notes](https://github.com/actions/cache/releases) - [Commits](https://github.com/actions/cache/compare/v2.1.5...v2.1.6) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
96 lines
2.5 KiB
YAML
96 lines
2.5 KiB
YAML
name: Ubuntu clvm Test
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
tags:
|
|
- '**'
|
|
pull_request:
|
|
branches:
|
|
- '**'
|
|
|
|
jobs:
|
|
build:
|
|
name: Ubuntu clvm Test
|
|
runs-on: ${{ matrix.os }}
|
|
timeout-minutes: 30
|
|
strategy:
|
|
fail-fast: false
|
|
max-parallel: 4
|
|
matrix:
|
|
python-version: [3.7, 3.8, 3.9]
|
|
os: [ubuntu-latest]
|
|
|
|
steps:
|
|
- name: Cancel previous runs on the same branch
|
|
if: ${{ github.ref != 'refs/heads/main' }}
|
|
uses: styfle/cancel-workflow-action@0.9.0
|
|
with:
|
|
access_token: ${{ github.token }}
|
|
|
|
- name: Checkout Code
|
|
uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Setup Python environment
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
- name: Cache npm
|
|
uses: actions/cache@v2.1.6
|
|
with:
|
|
path: ~/.npm
|
|
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-node-
|
|
|
|
- name: Get pip cache dir
|
|
id: pip-cache
|
|
run: |
|
|
echo "::set-output name=dir::$(pip cache dir)"
|
|
|
|
- name: Cache pip
|
|
uses: actions/cache@v2.1.6
|
|
with:
|
|
path: ${{ steps.pip-cache.outputs.dir }}
|
|
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-pip-
|
|
|
|
# Omitted checking out blocks and plots repo Chia-Network/test-cache
|
|
|
|
- name: Link home directory
|
|
run: |
|
|
cd $HOME
|
|
ln -s $GITHUB_WORKSPACE/.chia
|
|
echo "$HOME/.chia"
|
|
ls -al $HOME/.chia
|
|
|
|
- name: Install ubuntu dependencies
|
|
run: |
|
|
sudo apt-get install software-properties-common
|
|
sudo add-apt-repository ppa:deadsnakes/ppa
|
|
sudo apt-get update
|
|
sudo apt-get install python${{ matrix.python-version }}-venv python${{ matrix.python-version }}-distutils git -y
|
|
|
|
- name: Run install script
|
|
env:
|
|
INSTALL_PYTHON_VERSION: ${{ matrix.python-version }}
|
|
run: |
|
|
sh install.sh
|
|
|
|
# Omitted installing Timelord
|
|
|
|
- name: Install developer requirements
|
|
run: |
|
|
. ./activate
|
|
venv/bin/python -m pip install pytest pytest-asyncio pytest-xdist
|
|
|
|
- name: Test clvm code with pytest
|
|
run: |
|
|
. ./activate
|
|
./venv/bin/py.test tests/clvm/test_chialisp_deserialization.py tests/clvm/test_clvm_compilation.py tests/clvm/test_puzzles.py tests/clvm/test_serialized_program.py -s -v --durations 0 -n auto
|