tests: Detect tests by checking any matching file prefix

We were testing only for .ioctl files, but we may now have .pcap file
and ended up simply not running the synaptics test unless there was
still a .ioctl file present.
This commit is contained in:
Benjamin Berg 2021-06-28 16:16:31 +02:00
parent cdaa3497d7
commit d5fda36bc0

View file

@ -111,10 +111,10 @@ def custom():
['%s' % os.path.join(ddir, "custom.py")]) ['%s' % os.path.join(ddir, "custom.py")])
try: try:
if os.path.exists(os.path.join(ddir, "capture.ioctl")): if glob.glob(os.path.join(ddir, "capture.*")):
capture() capture()
if os.path.exists(os.path.join(ddir, "custom.ioctl")): if glob.glob(os.path.join(ddir, "custom.*")):
custom() custom()
except Exception as e: except Exception as e: