chore: Update end to end q7 tests#736
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates the Q7 end-to-end tests to use real Home Assistant mock product and device data instead of placeholder data derived from Q10/SS07. The changes include adding two new JSON test data files for the Q7 device and its product schema (SC01), updating mock data imports, and refactoring the test to use the actual device ID ("device-id-q7" instead of "device-id-def456").
Key changes:
- Added authentic Q7 device and product data files based on Home Assistant mock data
- Updated test to use real device ID, name, and product references
- Snapshot changes reflect the device ID change in MQTT topic paths
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tests/testdata/home_data_product_sc01.json | New file containing Q7 Series (SC01 model) product schema with 24 device properties and commands |
| tests/testdata/home_data_device_q7.json | New file containing Q7 device configuration including device status values and metadata |
| tests/mock_data.py | Added imports for SC01_PRODUCT_DATA and Q7_DEVICE_DATA to make them available for tests |
| tests/e2e/test_device_manager.py | Replaced placeholder Q7 test data with actual mock data references and updated device ID/name assertions |
| tests/e2e/snapshots/test_device_manager.ambr | Updated MQTT message snapshots to reflect the device ID change from "device-id-def456" to "device-id-q7" |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "category": "robot.vacuum.cleaner", | ||
| }, | ||
| ], | ||
| **HOME_DATA_RAW, |
There was a problem hiding this comment.
The dictionary unpacking **HOME_DATA_RAW is duplicated on lines 454 and 457. This will cause the second unpacking to overwrite any keys from the first. Since both unpack the same dictionary, this is redundant. Remove the duplicate on line 457.
| **HOME_DATA_RAW, |
ea26e7e to
6acabe8
Compare
Update the q7 end to end data using the home assistant mock product data and device response. The snapshot changes are strictly because the device id has changed.