Commit graph velofy/tests/console
Author SHA1 Message Date
049a5f6f62
Remove periods from one-sentence comments 2026-12-03 10:04:43 +01:00
35d0c7b409
Test reading the database revision
All checks were successful
CI / Checks (Python 3.13) (push) Successful in 2m50s
In the "sequentially" variant of the test database,
`current_db_revision()` must return the head of the migrations;
in the "all_at_once" variant, there is no version table.
2026-12-02 13:56:04 +01:00
2add322a25
Test the revision lock of the CLI stages
The `@db_revision` decorator no longer skips its check under `TESTING`.

The tests replace `current_db_revision()` with the revision they need.
2026-12-02 13:42:04 +01:00
c1f04c65aa
Count rows with select() in the tests
`Session.query()` is the legacy API in SQLAlchemy 2.x.
2026-12-01 23:17:57 +01:00
c56fe649b7
Enable RUF in ruff 2026-11-30 23:17:41 +01:00
07e90b7851
Import click.testing as cli_testing
Like `click.core` as `cli_core`
2026-11-30 20:01:43 +01:00
ea8f1a13e3
Use double quotes 2026-11-28 03:26:13 +01:00
9fcb3c8c14
Remove all "WPS" codes 2026-11-28 03:25:20 +01:00
c310c335ff
Upgrade click
Since `click` v8.2, a `Group` invoked without a subcommand
exits with status code 2 ("usage error") instead of 0.
2026-11-25 12:45:59 +01:00
dbdce83067
Upgrade black 2026-11-25 10:30:47 +01:00
8eb0dda0e1
Point the project URLs and texts to velofy 2026-11-24 10:34:32 +01:00
e7a2d4a3cb
Rename the umd CLI into manage 2026-11-24 10:02:34 +01:00
4855209392
Rename the urban_meal_delivery package into velofy 2026-11-23 18:06:53 +01:00
1bfc7db916
Make Grid.gridify() use only pickup addresses
- ensure a `Restaurant` only has one unique `Order.pickup_address`
- rework `Grid.gridify()` so that only pickup addresses are assigned
  into `Pixel`s
- include database migrations to ensure the data adhere to these
  tighter constraints
2021-01-24 19:04:39 +01:00
9196c88ed4
Remove pylint from the project 2021-01-09 17:47:45 +01:00
54ff377579
Add CLI script to gridify all cities
- reorganize `urban_meal_delivery.console` into a sub-package
- move `tests.db.conftest` fixtures into `tests.conftest`
  => some integration tests regarding CLI scripts need a database
- add `urban_meal_delivery.console.decorators.db_revision` decorator
  to ensure the database is at a certain state before a CLI script runs
- refactor the `urban_meal_delivery.db.grids.Grid.gridify()` constructor:
  - bug fix: even empty `Pixel`s end up in the database temporarily
    => create `Pixel` objects only if an `Address` is to be assigned
       to it
  - streamline code and docstring
  - add further test cases
2021-01-06 16:17:05 +01:00