Skip to content

Commit

Permalink
Merge pull request #1 from Deric-W/ci
Browse files Browse the repository at this point in the history
Add CI
  • Loading branch information
Deric-W authored Aug 22, 2022
2 parents 44bf110 + fd2360e commit c842e70
Show file tree
Hide file tree
Showing 3 changed files with 60 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/codecov.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
coverage:
status:
project:
default:
informational: true
patch:
default:
informational: true
49 changes: 49 additions & 0 deletions .github/workflows/Tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Tests

on: [push, workflow_dispatch]

jobs:
Test:
strategy:
matrix:
python-version: ["3.10"]
os: [ubuntu-latest]

runs-on: ${{ matrix.os }}

steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Install test dependencies
run: python -m pip install --no-cache-dir mypy coverage build

- name: Run MyPy
run: python -m mypy --cache-dir=/dev/null -p lambda_calculus

- name: Build wheel
run: python -m build

- name: Install wheel
run: python -m pip install --no-cache-dir dist/lambda_calculus-*.whl

- name: Run tests and generate report
run: coverage run -m unittest discover --verbose

- name: Upload coverage
uses: codecov/codecov-action@v3
with:
flags: ${{ runner.os }}
verbose: true

- name: Publish package
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}
verbose: true
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# lambda_calculus

![Tests](https://github.com/Deric-W/lambda_calculus/actions/workflows/Tests.yaml/badge.svg)
[![codecov](https://codecov.io/gh/Deric-W/lambda_calculus/branch/main/graph/badge.svg?token=SU3982mC17)](https://codecov.io/gh/Deric-W/lambda_calculus)

The `lambda_calculus` package contains classes which implement basic operations of the lambda calculus.

To use it, simply import the classes `Variable`, `Abstraction` and `Application` from this package
Expand Down

0 comments on commit c842e70

Please sign in to comment.