debugging github actions #5
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
#========================================================================= | |
# run-pymtl-tests.yml | |
#========================================================================= | |
# This workflow illustrates how to use the verilator-ci-cache with | |
# GitHub actions to run pymtl3 tests. | |
name: Python package | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
test_cmd: | |
- ../tut3_verilog | |
- ../lab1_imul | |
- ../lab2_proc | |
- ../lab3_mem | |
- ../lab4_sys | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: 3.11 | |
- name: Install verilator | |
run: | | |
wget --progress=dot:giga https://github.com/pymtl/verilator-ci-cache/raw/master/verilator-github-actions-5.026.tar.gz | |
echo $PWD | |
whoami | |
tar -C ${HOME} -xzf verilator-github-actions-5.026.tar.gz | |
echo "${HOME}/verilator/bin" >> $GITHUB_PATH | |
echo "PKG_CONFIG_PATH=${HOME}/verilator/share/pkgconfig:${PKG_CONFIG_PATH}" >> $GITHUB_ENV | |
- name: Check verilator | |
run: | | |
which verilator | |
verilator --version | |
pkg-config --modversion verilator | |
pkg-config --cflags verilator | |
- name: Install dependencies | |
run: | | |
sudo apt-get install -y graphviz | |
git clone https://github.com/pymtl/pymtl3 | |
cd pymtl3 | |
git checkout pymtl4.0-dev | |
pip install --upgrade pip | |
pip install -r requirements.txt | |
pip install -e . | |
pip list | |
- name: Run tests | |
run: | | |
mkdir -p pymtl3/build && cd pymtl3/build | |
pytest ../pymtl3 | |