Skip to content

Commit

Permalink
added scripts for extended testing
Browse files Browse the repository at this point in the history
  • Loading branch information
hugsy committed Nov 12, 2024
1 parent 9f2737a commit aa03373
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/extended-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Extended Tests


on:
workflow_dispatch:

jobs:
build:
strategy:
fail-fast: false
matrix:
variants:
- { os: fedora, version: 41 }
- { os: debian, version: bookworm }

name: "Tests on ${{ matrix.variants }}"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- run: |
docker run -v ${PWD}:/gef ${{ matrix.variants.os }}:${{ matrix.variants.version }} "bash /gef/tests/extended/${{ matrix.variants.os }}.sh"
16 changes: 16 additions & 0 deletions tests/extended/debian.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash
set -e
# set -x
# docker run -v /path/to/gef:/gef debian:bookworm "bash /gef/tests/extended/debian.sh"
apt update -qq
apt install -qq -y gdb-multiarch cmake gcc-multilib python3 python3-pip procps file elfutils binutils cmake gcc g++ gdbserver qemu-user locales
rm -rf /var/lib/apt/lists/* && localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
export LANG=en_US.utf8
export LC_ALL=en_US.utf8

cd /gef
export PY_VER=`gdb-multiarch -q -nx -ex "pi print('.'.join(map(str, sys.version_info[:2])))" -ex quit`
echo Using Python ${PY_VER}
python${PY_VER} -m pip install --user --upgrade -r tests/requirements.txt -r docs/requirements.txt --break-system-packages
make -C tests/binaries
python${PY_VER} -m pytest -v -m "not benchmark" tests/
15 changes: 15 additions & 0 deletions tests/extended/fedora.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash
set -e
# set -x
# docker run -v /path/to/gef:/gef fedora:41 "bash /gef/tests/extended/fedora.sh"
dnf install -y gdb cmake gcc python3 python3-pip procps file elfutils binutils cmake gcc g++ gdbserver qemu-user
export LANG=en_US.utf8
export LC_ALL=en_US.utf8

cd /gef
alias gdb-multiarch=gdb
export PY_VER=`gdb-multiarch -q -nx -ex "pi print('.'.join(map(str, sys.version_info[:2])))" -ex quit`
echo Using Python ${PY_VER}
python${PY_VER} -m pip install --user --upgrade -r tests/requirements.txt -r docs/requirements.txt --break-system-packages
make -C tests/binaries
python${PY_VER} -m pytest -v -m "not benchmark" tests/

0 comments on commit aa03373

Please sign in to comment.