Skip to content

Commit

Permalink
ci: Add build and tests
Browse files Browse the repository at this point in the history
  • Loading branch information
colluca committed Mar 19, 2024
1 parent b119a88 commit a18bd3e
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 5 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Copyright 2024 ETH Zurich and University of Bologna.
# Licensed under the Apache License, Version 2.0, see LICENSE for details.
# SPDX-License-Identifier: Apache-2.0

name: Test PyFlexFloat library
on: [push, pull_request]

jobs:
test:
name: Build and test package
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.9"
- name: Build
run: pip install .
- name: Install requirements
run: pip install -r requirements.txt
- name: Test
run: ./test/test.py
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
[build-system]
requires = [
"setuptools>=60",
"setuptools>=65.0",
"setuptools-scm>=8.0",
"cmake_build_extension==0.5.2.dev15",
"cffi"
]
build-backend = "setuptools.build_meta"
Expand Down
5 changes: 2 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@
#
# Author: Luca Colagrande <[email protected]>
import setuptools
import cmake_build_extension
from setuptools.command.build import build
import subprocess
from pathlib import Path


class CMakeBuild(setuptools.command.build.build):
class CMakeBuild(build):

def run(self):
# Required to generate "flexfloat_config.h"
Expand Down

0 comments on commit a18bd3e

Please sign in to comment.