SmartThingsEdgeDrivers icon indicating copy to clipboard operation
SmartThingsEdgeDrivers copied to clipboard

Add unit tests for appliances, rvc, and room ac

Open ctowns opened this issue 1 year ago • 8 comments

Some of the Matter 1.2 device type unit tests were left out of the repo so that CI unit tests would not continuously fail due to missing capability definitions in the integration test framework. Once the CI is updated to use the latest lua libs, we can add these tests to the repo because the capability definitions will then be available in the CI lua libs.

Note: This issue is strictly related to unit tests - new capabilities do not have a lua libs dependency on hubs, so even old hubs will get the new capability definitions even if they are running older lua libs.

These unit test all pass locally when running the latest lua libs.

ctowns avatar Jun 16 '24 20:06 ctowns

Duplicate profile check: Passed - no duplicate profiles detected.

github-actions[bot] avatar Jun 16 '24 20:06 github-actions[bot]

Test Results

   61 files  ± 0    378 suites  +3   0s :stopwatch: ±0s 1 836 tests +15  1 827 :white_check_mark: + 6  0 :zzz: ±0  5 :x: +5  4 :fire: +4  3 192 runs  +23  3 182 :white_check_mark: +13  0 :zzz: ±0  6 :x: +6  4 :fire: +4 

For more details on these failures and errors, see this check.

Results for commit 2f693f7b. ± Comparison against base commit 2125c846.

:recycle: This comment has been updated with latest results.

github-actions[bot] avatar Jun 16 '24 20:06 github-actions[bot]

matter-appliance_coverage.xml

File Coverage
All files 47% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 40% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry-washer/init.lua 42% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 47% :x:

matter-rvc_coverage.xml

File Coverage
All files 48% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 40% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry-washer/init.lua 42% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 47% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-rvc/src/init.lua 48% :x:

matter-thermostat_coverage.xml

File Coverage
All files 81% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/embedded-cluster-utils.lua 40% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-dishwasher/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/init.lua 50% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-laundry-washer/init.lua 42% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-appliance/src/matter-refrigerator/init.lua 47% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-rvc/src/init.lua 48% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-thermostat/src/embedded-cluster-utils.lua 42% :x:
/home/runner/work/SmartThingsEdgeDrivers/SmartThingsEdgeDrivers/drivers/SmartThings/matter-thermostat/src/init.lua 83% :x:

Minimum allowed coverage is 90%

Generated by :monkey: cobertura-action against 2f693f7bade03514d76e7a20e532272a48e2e2e0

github-actions[bot] avatar Jun 16 '24 20:06 github-actions[bot]

We can merge these in once CI lua libs have been updated. I will follow up on what the timing will be to update the lua libs.

@HunsupJung @yhoyoon I have tried to go through and write unit tests for the major functionality of the appliance, rvc, and room ac device types, but please take a look and add additional unit tests if there are any additional cases to test. Thank you!

Note, some of these unit tests are from the original Matter 1.2 device types PR, but they were intentionally removed to prevent CI unit tests from continuously failing. However, these tests all pass when running locally with the latest lua libs.

ctowns avatar Jun 16 '24 20:06 ctowns

Invitation URL: https://bestow-regional.api.smartthings.com/invite/Boj0AKe7rJMA

github-actions[bot] avatar Jun 16 '24 20:06 github-actions[bot]

I just published the 53 release of the lua libs. Are these unit test changes still needed? They are running against those libs now.

cjswedes avatar Jul 03 '24 15:07 cjswedes

@ctowns Should we keep or close this PR?

lelandblue avatar Jul 16 '24 14:07 lelandblue

@ctowns can this ticket be closed?

hcarter-775 avatar Oct 02 '24 02:10 hcarter-775