mirror of https://github.com/YosysHQ/yosys.git
docs: Debugging macro test fail
Call yosys-config post build extraction for sanity check. Report absolute path for yosys exe if it can't be found.
This commit is contained in:
parent
112a5cfc67
commit
6f602e79d4
|
@ -72,8 +72,9 @@ jobs:
|
|||
|
||||
test-yosys:
|
||||
name: Run tests
|
||||
needs: build-yosys
|
||||
runs-on: ${{ matrix.os }}
|
||||
needs: [build-yosys, pre_job]
|
||||
if: needs.pre_job.outputs.should_skip != 'true'
|
||||
env:
|
||||
CC: clang
|
||||
strategy:
|
||||
|
@ -122,6 +123,10 @@ jobs:
|
|||
run:
|
||||
tar -xvf build.tar
|
||||
|
||||
- name: Log yosys-config output
|
||||
run: |
|
||||
./yosys-config || true
|
||||
|
||||
- name: Run tests
|
||||
shell: bash
|
||||
run: |
|
||||
|
@ -132,3 +137,39 @@ jobs:
|
|||
shell: bash
|
||||
run: |
|
||||
find tests/**/*.err -print -exec cat {} \;
|
||||
|
||||
test-docs:
|
||||
name: Run docs tests
|
||||
runs-on: ${{ matrix.os }}
|
||||
needs: [build-yosys, pre_job]
|
||||
if: needs.pre_job.outputs.should_skip != 'true'
|
||||
env:
|
||||
CC: clang
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-20.04, macos-13]
|
||||
steps:
|
||||
- name: Checkout Yosys
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup environment
|
||||
uses: ./.github/actions/setup-build-env
|
||||
|
||||
- name: Download build artifact
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: build-${{ matrix.os }}
|
||||
|
||||
- name: Uncompress build
|
||||
shell: bash
|
||||
run:
|
||||
tar -xvf build.tar
|
||||
|
||||
- name: Log yosys-config output
|
||||
run: |
|
||||
./yosys-config || true
|
||||
|
||||
- name: Run tests
|
||||
shell: bash
|
||||
run: |
|
||||
make -C docs test -j${{ env.procs }}
|
||||
|
|
|
@ -12,12 +12,13 @@ logging.basicConfig(level=logging.INFO)
|
|||
# expects __file__ = yosys/docs/tests/macro_commands.py
|
||||
TESTS_DIR = Path(__file__).parent
|
||||
ROOT_DIR = TESTS_DIR.parent.parent
|
||||
logging.log(logging.INFO, f"Using {ROOT_DIR.absolute()} as root directory")
|
||||
THIS_FILE = (TESTS_DIR / "macro_commands.py").relative_to(ROOT_DIR)
|
||||
MACRO_SOURCE = TESTS_DIR.parent / "source" / "code_examples" / "macro_commands"
|
||||
assert MACRO_SOURCE.exists(), f"can't find macro_commands in {MACRO_SOURCE}"
|
||||
assert MACRO_SOURCE.exists(), f"can't find macro_commands in {MACRO_SOURCE.absolute()}"
|
||||
|
||||
YOSYS = TESTS_DIR.parent.parent / "yosys"
|
||||
assert YOSYS.exists(), f"can't find yosys executable in {YOSYS}"
|
||||
YOSYS = ROOT_DIR / "yosys"
|
||||
assert YOSYS.exists(), f"can't find yosys executable in {YOSYS.absolute()}"
|
||||
|
||||
raise_error = False
|
||||
# get all macro commands being used
|
||||
|
|
Loading…
Reference in New Issue