File: TODO.md

package info (click to toggle)
pytest-logdog 0.1.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 116 kB
  • sloc: python: 329; makefile: 3
file content (17 lines) | stat: -rw-r--r-- 1,203 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# To-do list (temporary)

All items here are subject for discussion.

## Features

### Filters

* [ ] A way to filter by exact value of `level`? `level` + `level_exact`? or `level_ge` + `level_eq`?.

### Other

* [ ] `assert_one_pop()` to pop matching and assert only one.  Is it possible to provide custome error message with similar records?   Or full list if it has limitted size.
* [ ] Add methods like `get_text()` to `LogPile` (note, it's also returned from `filter` and `drain`)?
* [ ] Some way to automate `assert pile.is_empty()`? In `__exit__`?
* [ ] Capture all by default for root (i.e. reset to `NOTSET`)? If so, the fixture itself should have pile interface.
* [ ] Return `LogDog` instance from fixture and provide `__call__` method?  This would simplfy annotation (`def test_smth(logdog: LogDog)` instead of current `def test_smth(logdog: Type[LogDog])`), but it also allow undesirable `with logdog as pile`.  Rename `LogDog` to `LogDocContext` and define `LogDog` with `__call__`?  Export `LogDog` in top-level package to allow `from pytest_logdog import LogDog`?  Or may be enter context and return `Pile` from fixture and provide `__call__` method in it to allow using without `with`?