pypiserver/tests
Mason Lin ae3dcf2bbd
feat: 🩺 allow customized health check endpoint (#442)
* feat: 🩺 allow customized health check endpoint

Get the liveness endpoint from the environment variable `HEALTH_ENDPOINT` and verify it. If the customized endpoint is invalied, it will fallback to the DEFAULT_HEALTH_ENDPOINT.

* test:  Test customized endpoint feature

* fix: 🚨 fix check

* feat: Use CLI interface to set health endpoint

* style: 💄 fix black format

* Separate 'build app' and 'add routes'

https://github.com/pypiserver/pypiserver/pull/442#discussion_r973771421

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* keep DEFAULTS in config.py

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* style alignment

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* make CLI arg description more clear

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* style: 🎨 style alignment

* refactor:  SRP, add routes after app created, instead of patching in app_from_config

* style: 🎨 format CLI help

* test:  add test_setup_routes_from_config

* fix: 🐛 test name doesn't work as expected because of using the wrong ids generator.

* test: 🧪 add config error cases for health endpoint

* test:  fix health_endpoint_arg tests

* fix:  Do not fallback to default silently, should raise error

* test: 🧪 add test_health_endpoint in test_main

* test:  setup routes in main

* docs: 📝 Update the help command output in the Quickstart

* docs: 🐛 missing space

* docs: 📝 Add 'Custom Health Check Endpoint' to 'Recipes'

* docs: 📝 refine README

* revert:  revert auto isoft

* build: 💚 fix mypy, missing return types

* Update README.rst

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* Update README.rst

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* Update pypiserver/config.py

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* Update README.rst

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

* style: 💄 black format

* Update README.rst

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>

Co-authored-by: Dmitrii Orlov <dmtree.dev@yahoo.com>
2022-11-02 12:32:20 +01:00
..
__init__.py Added init.py to tests 2016-05-12 20:02:10 -05:00
doubles.py Cleanup code to python 3.6 (#342) 2020-10-07 20:45:51 -05:00
sample_msg.html Use bottle's SimpleTemplate engine to avoid XSS on welcome-page (#77). 2015-02-22 18:43:35 +01:00
test_app.py feat: 🩺 allow customized health check endpoint (#442) 2022-11-02 12:32:20 +01:00
test_backend.py Refactor storage operations into separate Backend classes (#348) 2021-02-02 11:44:29 -06:00
test_config.py feat: 🩺 allow customized health check endpoint (#442) 2022-11-02 12:32:20 +01:00
test_core.py Refactor storage operations into separate Backend classes (#348) 2021-02-02 11:44:29 -06:00
test_docs.py Cleanup code to python 3.6 (#342) 2020-10-07 20:45:51 -05:00
test_init.py feat: 🩺 allow customized health check endpoint (#442) 2022-11-02 12:32:20 +01:00
test_main.py feat: 🩺 allow customized health check endpoint (#442) 2022-11-02 12:32:20 +01:00
test_manage.py Refactor storage operations into separate Backend classes (#348) 2021-02-02 11:44:29 -06:00
test_pkg_helpers.py Refactor storage operations into separate Backend classes (#348) 2021-02-02 11:44:29 -06:00
test_server.py fix(setuptools-in-tests): add packages=[] in test setup (#425) 2022-03-31 10:09:16 +02:00
test-ignorelist Backwards-compatible argparse config (not yet in use) (#339) 2020-10-08 19:37:39 -05:00