Skip to content

Commit 859b73d

Browse files
committed
docs: Add a development guide
1 parent 0b521ab commit 859b73d

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

DEVELOPMENT.md

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# Development
2+
3+
Quickstart for functions-framework maintainers.
4+
5+
## Environment setup
6+
7+
Install [tox](https://pypi.org/p/tox), the test runner:
8+
9+
```
10+
$ python -m pip install -U tox
11+
```
12+
13+
## Running tests
14+
15+
All tests can be run with:
16+
17+
```
18+
$ python -m tox
19+
```
20+
21+
Tests for the current Python version can be run with:
22+
23+
```
24+
$ python -m tox -e py
25+
```
26+
27+
Tests for a specific Python version can be run with:
28+
29+
```
30+
$ python -m tox -e py3.12
31+
```
32+
33+
A specific test file (e.g. `tests/test_cli.py`) can be run with:
34+
35+
```
36+
$ python -m tox -e py -- tests/test_cli.py
37+
```
38+
39+
A specific test in the file (e.g. `test_cli_no_arguements` in `tests/test_cli.py`) can be run with:
40+
41+
```
42+
$ python -m tox -e py -- tests/test_cli.py::test_cli_no_arguments
43+
```
44+
45+
## Releasing
46+
47+
Releases are triggered via the [Release Please](https://github.com/apps/release-please) app, which in turn kicks off the [Release to PyPI](https://github.com/GoogleCloudPlatform/functions-framework-python/blob/main/.github/workflows/release.yml) workflow.

0 commit comments

Comments
 (0)