Skip to content

Tests

Tests #368

Workflow file for this run

name: Tests
on:
push:
pull_request:
workflow_dispatch:
schedule:
- cron: '0 0 * * 0' # weekly
env:
JOBS: 2
DEPS: libgmp-dev libmpfr-dev libqd-dev libtool autoconf python3-pip python3-dev python3-flake8
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
have_qd: [yes, no]
have_ld: [yes, no]
have_numpy: [yes, no]
env:
HAVE_QD: ${{ matrix.have_qd }}
HAVE_LONG_DOUBLE: ${{ matrix.have_ld }}
HAVE_NUMPY: ${{ matrix.have_numpy }}
steps:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Check out
uses: actions/checkout@v2
- name: Install prerequisites
run: |
sudo DEBIAN_FRONTEND=noninteractive apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt-get install $DEPS
- name: Dependencies
run: |
git clone https://github.com/fplll/fplll
cd fplll || exit
./autogen.sh
./configure --disable-static --prefix=/usr --with-max-enum-dim=64 --with-max-parallel-enum-dim=20
make -j $JOBS
sudo make install
cd ..
pip install Cython
pip install -r requirements.txt
pip install -r suggestions.txt
cd ..
rm -rf ./fplll
- name: Compile
run: |
python setup.py build_ext -j $JOBS
python setup.py install
- name: Test
run: PY_IGNORE_IMPORTMISMATCH=1 python -m pytest