Skip to content

feat: Add steami_screen examples.#350

Draft
Charly-sketch wants to merge 19 commits intomainfrom
feat/add-example-steami-screen
Draft

feat: Add steami_screen examples.#350
Charly-sketch wants to merge 19 commits intomainfrom
feat/add-example-steami-screen

Conversation

@Charly-sketch
Copy link
Copy Markdown
Contributor

Summary

Closes #270
Depends on PR #346

Changes

Checklist

  • ruff check passes
  • python -m pytest tests/ -k mock -v passes (no mock test broken)
  • Tested on hardware (if applicable)
  • README updated (if adding/changing public API)
  • Examples added/updated (if applicable)
  • Commit messages follow <scope>: <Description.> format

Add initial mock test coverage for the steami_screen driver.

## Added
- FakeDisplay backend to simulate a display device
- Basic property tests: center, radius, max_chars
- Core drawing API tests: clear, show, pixel, line, rect, text
- Text helpers: title, subtitle, value
- Widgets: bar, menu, face
- Advanced widgets smoke tests: graph, gauge, compass, watch
- Geometry helpers via public API: circle (outline and fill)
- Edge cases: empty subtitle, unknown face, invalid position fallback

Tests validate that high-level API correctly delegates to the display backend
by inspecting recorded calls.

## Notes
- Tests access the backend via `dev._d` due to runner scope limitations
- No hardware dependency (pure mock)

## Remaining work
- Validate exact layout/positions (not just call presence)
- Test scaling behavior (text scale, value rendering)
- Add snapshot/visual tests (e.g. Pillow backend)
- Add hardware tests for real displays (SSD1327, GC9A01)
- Improve coverage of edge cases (bounds, clipping, long text)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Add steami_screen examples.

1 participant