Skip to content

Add fixtures for test_kickstart test coverage#945

Draft
Mearman wants to merge 10 commits intocoredevices:mainfrom
Mearman:fix/test-kickstart
Draft

Add fixtures for test_kickstart test coverage#945
Mearman wants to merge 10 commits intocoredevices:mainfrom
Mearman:fix/test-kickstart

Conversation

@Mearman
Copy link
Contributor

@Mearman Mearman commented Mar 9, 2026

This pull request enables the test_kickstart unit test by adding the required PBI fixture files. The test was previously disabled in the BROKEN_TESTS list due to missing fixture dependencies.

Test Fixture Additions

  • Added 13 PBI fixture files for test_kickstart covering various health and activity rendering scenarios:
    • render_PBL_43681 and render_PBL_43717 - PBL health metric rendering
    • render_hr_bpm and render_hr_bpm_24h - Heart rate display (12-hour and 24-hour formats)
    • render_hr_bpm_obstructed and render_hr_bpm_obstructed_24h - Heart rate with obstruction
    • render_no_data - Empty state rendering
    • render_obstructed_area - Obstruction area visualization
    • render_steps_above_daily_avg and render_steps_above_daily_avg_24h - Step count above daily average
    • render_steps_above_typical - Step count above typical range
    • render_steps_below_typical - Step count below typical range

BROKEN_TESTS Update

  • Removed test_kickstart.c from the BROKEN_TESTS list in tests/wscript, allowing the test to compile and run as part of the standard test suite.

Impact

  • Increases test coverage for the kickstart health/activity watchface app
  • Ensures rendering correctness for various health metrics and edge cases

@Mearman Mearman force-pushed the fix/test-kickstart branch 3 times, most recently from ead29ca to 998bd78 Compare March 9, 2026 20:14
@gmarull
Copy link
Member

gmarull commented Mar 9, 2026

commits follow area: short desc format, not type: short desc, please, see history

Mearman added 4 commits March 9, 2026 21:53
Require commit messages to use path-based areas (e.g., fw/drivers/hrm)
or known short areas (e.g., ci, docs, treewide) rather than conventional
commit types like feat:, fix:, chore:.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
Append -darwin suffix to fixture filenames on macOS to handle rendering
differences in font libraries. Linux (CI) uses standard ~platform naming
to match existing fixtures.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
Use memcpy for BD_ADDR_t address fields instead of direct assignment,
which was causing incorrect address comparisons in whitelist operations.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
Add run-tests-docker.sh to run tests in Docker matching CI environment,
and generate-linux-fixtures.sh to generate Linux-specific test fixtures.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
@Mearman Mearman force-pushed the fix/test-kickstart branch 2 times, most recently from 9e8e49f to a6a6101 Compare March 9, 2026 22:12
Document the cross-platform fixture naming scheme, Docker testing
workflow, and troubleshooting for CI vs local test discrepancies.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
@Mearman Mearman force-pushed the fix/test-kickstart branch from a6a6101 to f712aa2 Compare March 9, 2026 22:57
Mearman added 3 commits March 9, 2026 23:08
Restore platform suffix on Linux (e.g. ~spalding) while keeping the
additional -darwin suffix for macOS local development. This matches
the naming convention of the PNG fixture files in the repository.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
Add expected output fixtures for test_kickstart tests covering
various display states including heart rate, steps, and obstructed areas.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
Remove test_kickstart.c from BROKEN_TESTS now that fixtures are available.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
@Mearman Mearman force-pushed the fix/test-kickstart branch from d9b8463 to 3fecf75 Compare March 10, 2026 05:38
Mearman added 2 commits March 10, 2026 06:27
Create symlinks with ~spalding suffix for Linux CI compatibility.

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
The kickstart tests were failing on Linux CI because the fixtures
were generated on macOS which renders differently. Updated the
spalding platform fixtures with Linux-rendered images for:
- test_kickstart__render_PBL_43717
- test_kickstart__render_steps_above_daily_avg
- test_kickstart__render_steps_above_daily_avg_24h

Co-authored-by: Claude <[email protected]>

Signed-off-by: Joseph Mearman <[email protected]>
@Mearman Mearman marked this pull request as draft March 10, 2026 16:01
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.

2 participants