Skip to content

Commit

Permalink
Improved Testing and CI (#27)
Browse files Browse the repository at this point in the history
* added CI workflow

* added badge to README

* added proper setuptools interfacing

This PR exhibits only minor tweaks to existing code, and seeks to organize future versions of SSJ. All further PRs will need to pass integration tests before merging into main, and will allow us to more efficiently identify breaking changes where they would otherwise be ignored.

Note: this request does not add any additional integration tests.
  • Loading branch information
charlesknipp authored Sep 9, 2024
1 parent 5764a6e commit eb4ac4c
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# This workflow will install Python dependencies and run tests with a variety of Python versions
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python

name: CI

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.9", "3.10", "3.11"]

steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install pytest setuptools wheel
python -m pip install .
- name: Test with pytest
run: |
pytest
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Sequence-Space Jacobian (SSJ)

[![CI](https://github.com/shade-econ/sequence-jacobian/actions/workflows/main.yml/badge.svg)](https://github.com/shade-econ/sequence-jacobian/actions/workflows/main.yml)

SSJ is a toolkit for analyzing dynamic macroeconomic models with (or without) rich microeconomic heterogeneity.

The conceptual framework is based on our paper Adrien Auclert, Bence Bardóczy, Matthew Rognlie, Ludwig Straub (2021), [Using the Sequence-Space Jacobian to Solve and Estimate Heterogeneous-Agent Models](https://doi.org/10.3982/ECTA17434), Econometrica 89(5), pp. 2375–2408 [[ungated copy]](http://mattrognlie.com/sequence_space_jacobian.pdf).
Expand Down
4 changes: 4 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ package_dir =
= src
packages = find:
python_requires = >=3.7
install_requires =
numpy >= 1.19.2
scipy >= 1.2
numba >= 0.49

[options.packages.find]
where = src

0 comments on commit eb4ac4c

Please sign in to comment.