Skip to content

Commit a1c4cf2

Browse files
docs: add pytest instructions
1 parent 7f650d9 commit a1c4cf2

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

docs/contributing/app-dev.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,12 @@ streamlit run app.py
4949

5050
### Application files
5151

52-
- `script/`: Developer workflow scripts following [GitHub's Scripts To Rule Them All](https://github.com/github/scripts-to-rule-them-all) pattern.
5352
- `app.py`: Main source for the application
53+
- `test_app.py`: [pytest](https://docs.pytest.org/en/latest/) tests for `app.py`
54+
- `script/`: Developer workflow scripts following [GitHub's Scripts To Rule Them All](https://github.com/github/scripts-to-rule-them-all) pattern.
5455
- `.streamlit/`: [Streamlit config options](https://docs.streamlit.io/cli.html)
5556
- `.env`: Local environment variables to use when running application, this file is copied from `.env.example` to start you out and then ignored by git
57+
- `pytest.ini`: Configuration for [pytest](https://docs.pytest.org/en/latest/)
5658
- `Pipfile`
5759
- `Pipfile.lock`
5860
- `environment.yml`
@@ -74,7 +76,14 @@ streamlit run app.py
7476

7577
## Testing
7678

77-
*No testing routine is available yet. If you have thoughts on how to add one, please contribute!*
79+
The project is set up for testing with [pytest](https://docs.pytest.org/en/latest/), and the GitHub repository is configured to execute `pytest` against all pull requests automatically.
80+
81+
To run tests locally, enter an environment first with `pipenv` or `conda` as indicated above in [Running CHIME Locally](#running-chime-locally), and then run:
82+
83+
```bash
84+
pip install pytest
85+
pytest
86+
```
7887

7988
## Validating CHIME
8089

0 commit comments

Comments
 (0)