libfprint/tests
xiaofei 631da4654f focaltechmoc:Support FocalTech moc devices
Supported UID: 0x2808
    Supported PIDs: 0x9E48, 0xD979, 0xa959
2024-02-13 14:34:12 +01:00
..
aes2501 tests: Add aes2501 driver replay test 2021-09-08 15:25:14 +02:00
aes3500 tests: Add trailing newline to busname/devname sysfs attributes 2021-01-21 11:28:47 +00:00
egis0570 tests/egis0570/capture.pcapng: Remove execution permission 2023-08-22 23:08:55 +00:00
elan tests: Add trailing newline to busname/devname sysfs attributes 2021-01-21 11:28:47 +00:00
elan-cobo tests: Add (another) elan driver replay test 2021-09-08 15:36:35 +02:00
elanmoc tests: Ensure python tests exit with error on every exception 2022-09-28 01:22:15 +02:00
elanspi elanspi: Adjust register tables (fixes #438) 2021-12-22 00:20:57 -05:00
focaltech_moc focaltechmoc:Support FocalTech moc devices 2024-02-13 14:34:12 +01:00
fpcmoc tests/fpcmoc: Ensure python tests exit with error on every exception 2022-10-13 04:26:58 +02:00
goodixmoc goodixmoc: Fix missing "enroll create" state 2023-01-19 20:28:33 +01:00
nb1010 Add nb1010 driver 2021-04-12 20:24:13 +02:00
realtek drivers: add realtek rts5813 driver 2023-10-27 13:21:06 +00:00
synaptics synaptics, goodix: Properly check for finger status during enroll progress 2022-09-28 01:21:31 +02:00
upektc_img tests: Add upektc_img test 2021-07-12 17:06:43 +02:00
upektc_img-tcs1s upektc_img: Add new unit test for the TCS1s chip variant 2023-01-17 19:50:21 +00:00
uru4000-4500 tests: Add U.are.U 4500 test 2021-09-09 10:54:48 +02:00
uru4000-msv2 tests: Add uru4000 test 2021-09-08 20:37:00 +02:00
vfs0050 tests: Add full USB device hierarchy 2021-08-09 16:08:21 +02:00
vfs301 tests: Add trailing newline to busname/devname sysfs attributes 2021-01-21 11:28:47 +00:00
vfs5011 tests: Add full USB device hierarchy 2021-08-09 16:08:21 +02:00
vfs7552 Added test for vfs7552 2021-03-12 11:29:43 +01:00
capture.py tests: Ensure python tests exit with error on every exception 2022-09-28 01:22:15 +02:00
create-driver-test.py.in tests: Reset the USB device before testing 2022-05-17 20:29:00 +02:00
driver.test.in tests: Add support for installed tests 2023-06-28 16:35:16 +02:00
hwdb-check-unsupported.py ci: Add check that wiki and generator are in sync 2021-01-20 17:21:38 +01:00
libfprint.supp tests: valgrind: update python and libfprint suppressions list 2023-01-10 11:15:17 -08:00
meson.build focaltechmoc:Support FocalTech moc devices 2024-02-13 14:34:12 +01:00
README.md tests: Run custom.py from test creation helper when available 2021-09-21 19:13:02 +02:00
test-device-fake.c test-device-fake: Add more logging showing the current device action 2022-10-13 20:31:28 +00:00
test-device-fake.h tests: Add suspend/resume tests 2021-08-09 16:08:21 +02:00
test-fp-context.c tests: Add support for creating other virtual readers 2021-01-20 23:21:04 +01:00
test-fp-device.c test-fp-device: Add few tests to check identification init errors 2022-07-14 21:35:30 +02:00
test-fpi-assembling.c tests: Use native GTest utils to generate assets names 2023-08-21 14:19:27 +00:00
test-fpi-device.c test-fpi-device: Only push pragma -wdanging-pointer in newer GCC versions 2023-03-15 15:23:17 +00:00
test-fpi-ssm.c ssm: Remove delayed action GCancellable integration 2021-04-28 22:16:37 +02:00
test-generated-hwdb.sh tests: make mktemp command call work with Chimera Linux's mktemp 2024-01-22 15:52:46 +00:00
test-utils.c virtual-device: Add non-image mock devices 2021-01-20 23:21:41 +01:00
test-utils.h virtual-device: Add non-image mock devices 2021-01-20 23:21:41 +01:00
test.in tests: Add support for installed tests 2023-06-28 16:35:16 +02:00
umockdev-test.py tests: Fix umockdev version detection 2022-08-16 17:14:07 +02:00
unittest_inspector.py tests: Make meson be aware of the single python unit tests 2020-02-10 11:41:40 +01:00
valgrind-python.supp tests: valgrind: update python and libfprint suppressions list 2023-01-10 11:15:17 -08:00
virtual-device.py tests/virtual-device: Check that removed devices are not in context anymore 2023-06-23 18:20:04 +02:00
virtual-image.py tests/virtual-image: Support passing specific FP_PRINTS_PATH env variable 2023-06-24 00:28:04 +02:00

umockdev Tests

umockdev tests use fingerprint devices mocked by umockdev toolchain.

This document describes how to create test cases (for USB devices). Many of these tests are tests for image devices, where a single image is captured and stored.

Other kinds of umockdev tests can be created in a similar manner. For match-on-chip devices you would instead create a test specific custom.py script, capture it and store the capture to custom.pcapng.

'capture' and 'custom' Test Creation

For image devices the capture.py script will be used to capture one reference image. If the driver is a non-image driver, then a custom.py script should be created in advance, which will be run instead.

  1. Make sure that libfprint is built with support for the device driver that you want to create a test case for.

  2. From the build directory, run tests/create-driver-test.py as root. Note that if you're capturing data for a driver which already has a test case but the hardware is slightly different, you might want to pass a variant name as a command-line options, for example:

$ sudo tests/create-driver-test.py driver [variant]
  1. If the capture is not successful, run the tool again to start another capture.

  2. Add driver test name to drivers_tests in the meson.build, as instructed, and change the ownership of the just-created test directory in the source.

  3. Check whether meson test passes with this new test.

Note. To avoid submitting a real fingerprint when creating a 'capture' test, the side of finger, arm, or anything else producing an image with the device can be used.

Possible Issues

Other changes may be needed to get everything working. For example the elan driver relies on a timeout that is not reported correctly. In this case the driver works around it by interpreting the protocol error differently in the virtual environment (by means of FP_DEVICE_EMULATION environment variable).