kosli-dev / tdd

Demo Python Gunicorn+Flask app skeleton

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Github Action (main)

The following blog posts link to this repo:

A public demo repo of

  • gunicorn running with multiple workers
  • each worker running a simple Flask web server (with an API)
  • the web server scores the XY Business Game by Jerry Weinberg
  • the web server runs inside a read-only Docker container
  • system tests with full branch coverage
  • unit tests with full branch coverage
$ source scripts/shortcuts.sh

$ rst          # Run all System Tests in new server ~10s
$ est          # Exec all System Tests in restarted server ~4s
$ rst 04692400 # Run only System Test 04692400 in new server
$ est 04692400 # Exec only System Test 04692400 in restarted server

$ rut          # Run all Unit Tests in new server ~10s
$ eut          # Exec all Unit Tests in existing server ~1s
$ rut a2189600 # Run only Unit Test a2189600 in new server
$ eut a2189600 # Exec only Unit Test a2189600 in existing server

$ ctc          # gather Combined Test Coverage
$ demo         # run a demo server on localhost:80
$ hup          # restart the demo server
$ tid          # generate a test id

About

Demo Python Gunicorn+Flask app skeleton

License:BSD 2-Clause "Simplified" License


Languages

Language:JavaScript 69.3%Language:Python 24.2%Language:Shell 4.9%Language:HTML 1.0%Language:Dockerfile 0.4%Language:SCSS 0.3%