arrow_backRetour aux issues
HafidIdrissi/Time-Tracker
#22
Débutant
Ouvrirarrow_forward
Débutant
Ouvrirarrow_forward
Débutant
Ouvrirarrow_forward
Add report-period clipping tests at date-range boundaries
ecoDébutant
enhancement
help wanted
good first issue
descriptionDescription
## User problem
`collect_periods()` clips stored activity to the selected report range and
recomputes durations. This is essential for accurate daily totals, but the
current report tests construct already-clipped periods and do not exercise this
boundary logic.
## Expected result
Add focused tests using a temporary `ActivityDatabase` and `Categorizer` to
verify clipping at both ends of a range.
## Likely files
- `tests/test_reporting.py`
- `timetracker/reporting.py` only if a test reveals a defect
## Acceptance criteria
- Cover a period that begins before the selected range.
- Cover a period that ends after the selected range.
- Cover a period spanning the entire range.
- Verify recalculated start, end, and `duration_seconds` values.
- Verify that zero-length results are omitted.
- Verify active category assignment and the fixed Idle label/category behavior.
- Use timezone-aware datetimes and avoid assumptions that every local day is
exactly 24 hours.
## Test command
```powershell
python -m unittest tests.test_reporting -v
python -m unittest discover -v
```
Issues similaires
calkit/calkit
star53
Poids du dépôt moyen
VS Code extension should be robust to YAML parser errors
Seeing this error: ``` Failed to read calkit.yaml: YAMLParseError: A block sequence may not be used as an implicit map…
Python
bug
good first issue
fu351/Doberman-Core
star211
Poids du dépôt léger
dash: a manual Refresh control
The dashboard polls: `refreshStats()` (`src/doberman/dash/app.py:408`) every 5 s and `refreshPending()` (`:546`) every …
Python
enhancement
good first issue
fu351/Doberman-Core
star211
Poids du dépôt léger
dash: "Copy details" button on each pending-approval card
Each pending-approval card in the dashboard (`renderPending`, `src/doberman/dash/app.py:448-544`) shows the risk badge,…
Python
enhancement
good first issue