Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
652 views
in Technique[技术] by (71.8m points)

testing - Mocking USB input

Our product includes some custom hardware, that connects to a PC via USB. We've started looking into automatic testing, but so far I'm unable to find a tool that can record/replay generic USB input.

Does anyone know of such a tool?
(And - it would be best if it's somehow scriptable - testing would have to alternate between GUI interaction and custom hardware manipulation)

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Mocking usb devices using umockdev

Umockdev is a linux based application which record the behaviour as well as properties of hardware and run the software independent of actual hardware it is running on. Hardware devices can be simulated in virtual environments without disturbing the whole system.It currently supports sysfs, uevents, basic support for /dev devices, and recording/mocking usbdevfs ioctls (for PtP/MTP devices). It helps for creating integration test for hardware related libraries.

source code and examples

umockdev home page


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...