edgexfoundry / device-usb-camera

Owner: Device WG
Apache License 2.0
12 stars 28 forks source link

fix: Both path and paths need to be supported to address the breaking change until the next release #290

Closed presatish closed 1 year ago

presatish commented 1 year ago

If your build fails due to your commit message not passing the build checks, please review the guidelines here: https://github.com/edgexfoundry/edgex-go/blob/main/.github/Contributing.md

PR Checklist

Please check if your PR fulfills the following requirements:

Testing Instructions

New Dependency Instructions (If applicable)

codecov-commenter commented 1 year ago

Codecov Report

Merging #290 (18a7ff3) into main (608e40c) will decrease coverage by 0.05%. The diff coverage is 0.00%.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

@@           Coverage Diff            @@
##            main    #290      +/-   ##
========================================
- Coverage   4.79%   4.74%   -0.05%     
========================================
  Files          8       8              
  Lines       1293    1306      +13     
========================================
  Hits          62      62              
- Misses      1231    1244      +13     
Files Changed Coverage Δ
internal/driver/device.go 2.83% <ø> (ø)
internal/driver/driver.go 3.21% <0.00%> (-0.06%) :arrow_down:
internal/driver/helper.go 80.95% <0.00%> (ø)
vyshali-chitikeshi commented 1 year ago

Though its already merged into main, I did validaiton to ensure end-to-end testing (discovering usb cameras, adding them egex metadata and rest-api's) works correctly both with 'path' and 'paths' fields and it looks good. Validated with below combinations of code:

  1. Latest (main branch) egex and Latest (main branch) USB code - works with 'paths'
  2. Latest (main branch) egex and 3.0 USB code - works with 'path'
  3. 3.0 egex and Latest (main branch) USB code - works with 'paths'
  4. 3.0 egex and 3.0 USB code - works with 'path

attaced scrresnhots for refecne. latest_edgex_and_3.0_usb_device_usb.txt 3.0_edgex_and_latest_usb_device_path.txt 3.0_edgex_and_3.0_usb_device_path.txt latest_edgex_and_latest_usb_device_path.txt