ci: fix ruff E501 + mypy None-comparison warning
test_imap.py:49 — one-line comment ran past the 100-char line limit
introduced in commit c830856. Split the "£20,000 cap" note onto its
own line above the call.
test_fidelity_planviewer.py:108 — mypy flagged `offset.amount > 0`
where amount is typed Decimal | None. Added an explicit `is not None`
guard; runtime behaviour unchanged (we already check offset is not
None two lines earlier).
$ poetry run ruff check . → All checks passed!
$ poetry run mypy broker_sync tests → Success: no issues found in 43 source files
$ poetry run pytest -q → 133 passed, 1 skipped
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
6450201af0
commit
6f3bcea23e
2 changed files with 3 additions and 2 deletions
|
|
@ -46,7 +46,8 @@ def test_single_tax_year_under_cap_stays_isa() -> None:
|
|||
def test_overflow_past_cap_flips_to_gia() -> None:
|
||||
acts = [
|
||||
_buy(datetime(2024, 5, 1, tzinfo=UTC), "100", "80"), # £8,000
|
||||
_buy(datetime(2024, 6, 1, tzinfo=UTC), "150", "80"), # +£12,000 → £20,000 total; prev £8k < cap → ISA
|
||||
# +£12,000 → £20,000 total; prev £8k < cap → ISA
|
||||
_buy(datetime(2024, 6, 1, tzinfo=UTC), "150", "80"),
|
||||
_buy(datetime(2024, 7, 1, tzinfo=UTC), "10", "80"), # prev £20,000 ≥ cap → GIA
|
||||
_buy(datetime(2024, 8, 1, tzinfo=UTC), "10", "80"), # GIA
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue