From 1910a4a5e7730d4d7e2f46ad0a0ed2c7f2d56a37 Mon Sep 17 00:00:00 2001 From: hugsy Date: Mon, 11 Nov 2024 17:07:25 -0800 Subject: [PATCH] added arch --- tests/extended/archlinux.sh | 13 +++++++++++++ tests/extended/debian.sh | 8 +------- tests/extended/fedora.sh | 9 +-------- tests/extended/run_pytest.sh | 10 ++++++++++ 4 files changed, 25 insertions(+), 15 deletions(-) create mode 100644 tests/extended/archlinux.sh create mode 100644 tests/extended/run_pytest.sh diff --git a/tests/extended/archlinux.sh b/tests/extended/archlinux.sh new file mode 100644 index 000000000..9a6a0d15d --- /dev/null +++ b/tests/extended/archlinux.sh @@ -0,0 +1,13 @@ + + +#!/bin/bash +set -e +# set -x +# docker run -v /path/to/gef:/gef archlinux:base-20241110.0.278197⁠ "bash /gef/tests/extended/archlinux.sh" +pacman -Suy +pacman -Suy --noconfirm gdb cmake gcc python3 procps file elfutils binutils cmake gcc qemu-user locales git python-pip make +export LANG=en_US.UTF8 +export LC_ALL=en_US.UTF8 + +alias gdb-multiarch=gdb +bash /gef/tests/extended/run_pytest.sh diff --git a/tests/extended/debian.sh b/tests/extended/debian.sh index 1564299b1..48839fd85 100644 --- a/tests/extended/debian.sh +++ b/tests/extended/debian.sh @@ -8,10 +8,4 @@ rm -rf /var/lib/apt/lists/* && localedef -i en_US -c -f UTF-8 -A /usr/share/loca export LANG=en_US.UTF8 export LC_ALL=en_US.UTF8 -git config --global --add safe.directory /gef -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 -j4 -python${PY_VER} -m pytest --forked -n 4 -v -m "not benchmark" tests/ +bash /gef/tests/extended/run_pytest.sh \ No newline at end of file diff --git a/tests/extended/fedora.sh b/tests/extended/fedora.sh index 4e9ed9458..285b90c30 100644 --- a/tests/extended/fedora.sh +++ b/tests/extended/fedora.sh @@ -6,11 +6,4 @@ dnf install -y gdb cmake gcc python3 python3-pip procps file elfutils binutils c export LANG=en_US.UTF8 export LC_ALL=en_US.UTF8 -git config --global --add safe.directory /gef -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 -j4 -python${PY_VER} -m pytest --forked -n 4 -v -m "not benchmark" tests/ +bash /gef/tests/extended/run_pytest.sh \ No newline at end of file diff --git a/tests/extended/run_pytest.sh b/tests/extended/run_pytest.sh new file mode 100644 index 000000000..3749a34a0 --- /dev/null +++ b/tests/extended/run_pytest.sh @@ -0,0 +1,10 @@ +#!/bin/bash +set -e + +git config --global --add safe.directory /gef +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 -j4 +python${PY_VER} -m pytest --forked -n 4 -v -m "not benchmark" tests/