VirtualBox

Ignore:
Timestamp:
Apr 18, 2016 5:35:25 PM (9 years ago)
Author:
vboxsync
Message:

ValidationKit/usb: Fixes for the USB testcase and enhance addUsbDeviceFilter

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/tests/usb/tdUsb1.py

    r60522 r60549  
    315315            self.oVBox.host.addUSBDeviceSource('USBIP', sGadgetHost, sGadgetHost + (':%s' % oUsbGadget.getUsbIpPort()), [], []);
    316316
    317             # Create device filter
    318             fRc = oSession.addUsbDeviceFilter('Compliance device', '0525', 'a4a0');
     317            # Create test device gadget and a filter to attach the device automatically.
     318            fRc = oUsbGadget.impersonate(usbgadget2.g_ksGadgetImpersonationTest);
    319319            if fRc is True:
    320                 fRc = oUsbGadget.impersonate(usbgadget2.g_ksGadgetImpersonationTest);
     320                iBusId, _ = oUsbGadget.getGadgetBusAndDevId();
     321                fRc = oSession.addUsbDeviceFilter('Compliance device', sVendorId = '0525', sProductId = 'a4a0', sPort = str(iBusId));
    321322                if fRc is True:
    322323
    323324                    # Wait a moment to let the USB device appear
    324                     self.sleep(10);
     325                    self.sleep(3);
    325326
    326327                    tupCmdLine = ('UsbTest', );
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette