Skip to content

Random contrained tests for simple register interface #142

Random contrained tests for simple register interface

Random contrained tests for simple register interface #142

Workflow file for this run

# Copyright 2023 - cryptopen contributors
# Licensed under the Apache License, Version 2.0, see LICENSE for details.
# SPDX-License-Identifier: Apache-2.0
name: RTL regression
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
paths:
- '**.sv'
- 'tb/**.py'
env:
ITERATIONS: 1000
MESSAGES: 50
VERILATOR_VERSION: v5.006
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r tb/requirements.txt
- name: Install verilator
run: |
sudo apt install -y --no-install-recommends help2man make g++ perl python3 autoconf flex bison libfl2 libfl-dev
git clone https://github.com/verilator/verilator.git
cd verilator
git reset --hard ${{ env.VERILATOR_VERSION }}
autoconf
./configure
make -j $(nproc)
sudo make install
- name: Run interface cocotb test suite
run: |
ITERATIONS=${{ env.ITERATIONS }} pytest tb/interface -vs
- name: Run sha1 cocotb test suite
run: |
pytest tb/sha1 -vs --ignore=tb/sha1/model
- name: Run sha2 cocotb test suite
run: |
pytest tb/sha2 -vs --ignore=tb/sha2/model
- name: Run all IPs top-level test suite
run: |
ITERATIONS=${{ env.MESSAGES }} pytest tb/test_tops.py -vs