-
-
Notifications
You must be signed in to change notification settings - Fork 2
test: save fixtures #363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: save fixtures #363
Conversation
📝 WalkthroughWalkthroughThis pull request adds configuration updates and new test fixture data files. A pre-commit configuration entry is modified to exclude JSON fixture files from spell checking, while 11 new JSON fixture files are introduced across bridge and vedo domains containing structured test data for room configurations, lighting, irrigation, scenarios, shutters, and security zones. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~15 minutes Poem
Pre-merge checks✅ Passed checks (3 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #363 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 2 2
Lines 50 50
=========================================
Hits 50 50 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds test fixture files containing JSON data for a home automation system, including alarm/security (vedo) and bridge controller configurations. The fixtures appear to represent a real home setup with Italian room and device names.
- Adds vedo alarm system fixtures for zones and areas (statistics and descriptions)
- Adds bridge controller fixtures for various device types (lights, shutters, climate, irrigation, scenarios, counters, other devices)
- Updates pre-commit configuration to skip codespell checks on fixture JSON files
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/fixtures/vedo/vedo_zone_stat.json | Zone statistics including status codes, authentication, and operational flags |
| src/fixtures/vedo/vedo_zone_desc.json | Zone descriptions with presence indicators and Italian room names (doors, windows, sensors) |
| src/fixtures/vedo/vedo_area_stat.json | Area statistics for alarm states (ready, armed, alarm, sabotage, etc.) |
| src/fixtures/vedo/vedo_area_desc.json | Area descriptions defining security zones (perimeter, volumetric, garage) |
| src/fixtures/bridge/shutter.json | Shutter/blind configuration for external awning and velux window |
| src/fixtures/bridge/scenario.json | Scenario definitions for exit automations (total, partial, robot) |
| src/fixtures/bridge/other.json | Other device configuration for a bedside outlet |
| src/fixtures/bridge/light.json | Light configuration for 32 lights across various rooms |
| src/fixtures/bridge/irrigation.json | Irrigation zone configuration for 4 garden zones |
| src/fixtures/bridge/counter.json | Counter/meter data with timestamp and instant readings |
| src/fixtures/bridge/clima.json | Climate control configuration for 4 zones with temperature and mode settings |
| .pre-commit-config.yaml | Adds codespell skip pattern for fixture JSON files to avoid false positives on Italian text |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: defaults
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (12)
.pre-commit-config.yamlsrc/fixtures/bridge/clima.jsonsrc/fixtures/bridge/counter.jsonsrc/fixtures/bridge/irrigation.jsonsrc/fixtures/bridge/light.jsonsrc/fixtures/bridge/other.jsonsrc/fixtures/bridge/scenario.jsonsrc/fixtures/bridge/shutter.jsonsrc/fixtures/vedo/vedo_area_desc.jsonsrc/fixtures/vedo/vedo_area_stat.jsonsrc/fixtures/vedo/vedo_zone_desc.jsonsrc/fixtures/vedo/vedo_zone_stat.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: release
🔇 Additional comments (11)
src/fixtures/vedo/vedo_zone_stat.json (1)
1-7: LGTM! Valid test fixture structure.The JSON structure is valid and appropriate for test fixture data. The long comma-separated status codes in the
statusfield are typical for zone status test data.src/fixtures/bridge/other.json (1)
1-24: LGTM! Consistent fixture structure.The JSON structure is valid with proper parallel array alignment. The
numfield (1) matches the array lengths, and theenvindex correctly references theenv_descmapping.src/fixtures/bridge/counter.json (1)
1-40: LGTM! Valid counter fixture data.The JSON structure is valid and appropriate for counter/meter test fixture data. The
instantarray with 31 elements and the timestamp indataorafollow a typical pattern for this type of fixture.src/fixtures/bridge/shutter.json (1)
1-24: LGTM! Consistent shutter fixture structure.The JSON structure is valid with proper parallel array alignment. The
numfield (2) matches the array lengths, and bothenvindices correctly reference theenv_descmapping.src/fixtures/vedo/vedo_area_desc.json (1)
1-19: Fixture data looks good.The JSON structure is valid and well-formed with consistent array dimensions (8 elements). Presence and descriptor data appear reasonable for a test fixture.
src/fixtures/bridge/irrigation.json (1)
1-29: Fixture data is well-structured and consistent.Array dimensions are properly aligned (num: 4 with four 4-element arrays for zones). The env_desc mapping of 13 location descriptors is a reasonable set of environment options, and zero-valued status arrays are appropriate for an initial test state.
src/fixtures/vedo/vedo_zone_desc.json (1)
1-409: The arrays invedo_zone_desc.jsonare properly aligned—description,in_area, andpresentall contain 382 elements, not the dimensions claimed in the original review. The sparse description array (with only 13 non-empty labels among 382 elements) reflects the intentional design for zone labeling in the VEDO fixture schema.src/fixtures/bridge/clima.json (1)
1-45: LGTM!Valid JSON fixture with consistent parallel arrays (all match
num: 4). Theenv_descarray correctly serves as a separate lookup table for environment descriptions.src/fixtures/vedo/vedo_area_stat.json (1)
1-15: LGTM!Valid JSON fixture with consistent zone arrays (all 8 elements). The structure correctly represents area statistics for a Vedo security system.
src/fixtures/bridge/scenario.json (1)
1-55: LGTM!Valid JSON fixture with correct array lengths matching
num: 32. The emptytypeandenv_descarrays appear intentional for scenario fixtures.src/fixtures/bridge/light.json (1)
1-72: LGTM!Valid JSON fixture with consistent parallel arrays matching
num: 32. Theenv_desclookup table aligns with the environment IDs used in theenvarray.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.