Skip to content

Add credit card reader test (New)#2300

Merged
rickwu666666 merged 8 commits intomainfrom
add-credit-card-reader-test
Mar 4, 2026
Merged

Add credit card reader test (New)#2300
rickwu666666 merged 8 commits intomainfrom
add-credit-card-reader-test

Conversation

@rickwu666666
Copy link
Contributor

Description

Add test for credit card reader. We develop the test script according to the Verifone's credit card reader. However, we check if the device echo ACK \x06 back after sending out enquiry string \x05 which is a quite common method to check if serial device's connection established.

Resolved issues

Documentation

Tests

sideload result
https://certification.canonical.com/hardware/202511-38101/submission/469103/test-results/

@rickwu666666 rickwu666666 requested a review from a team January 22, 2026 10:38
@rickwu666666 rickwu666666 added the ce-oem The PR only contains to the ce-oem provider under the contrib area label Jan 22, 2026
@rickwu666666 rickwu666666 marked this pull request as draft January 23, 2026 01:55
@rickwu666666
Copy link
Contributor Author

We have a credit card reader(verifone MX870) that is powered by USB port and communicate over serial port, which means checking device from the udevadm/lsusb output is not really mean that device connected and ready. Therefore, I will stay with current implamentation to send enquiry string to the device port and try to get the ACK form device.

@rickwu666666 rickwu666666 force-pushed the add-credit-card-reader-test branch from e413735 to 9099328 Compare January 26, 2026 06:17
@rickwu666666 rickwu666666 marked this pull request as ready for review January 26, 2026 06:17
Copy link
Collaborator

@stanley31huang stanley31huang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@rickwu666666 rickwu666666 merged commit 9a39659 into main Mar 4, 2026
16 checks passed
@rickwu666666 rickwu666666 deleted the add-credit-card-reader-test branch March 4, 2026 07:54
@codecov
Copy link

codecov bot commented Mar 4, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 54.88%. Comparing base (38b29e2) to head (f3006a4).
⚠️ Report is 47 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2300   +/-   ##
=======================================
  Coverage   54.88%   54.88%           
=======================================
  Files         412      412           
  Lines       44246    44246           
  Branches     8154     8154           
=======================================
  Hits        24284    24284           
  Misses      19132    19132           
  Partials      830      830           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ce-oem The PR only contains to the ce-oem provider under the contrib area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants