VirtualBox

Changeset 83401 in vbox for trunk


Ignore:
Timestamp:
Mar 25, 2020 10:59:09 AM (5 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
136618
Message:

Main: bugref:9341: Added methods to Session wrapper for the autostart test

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/ValidationKit/testdriver/vboxwrappers.py

    r82968 r83401  
    16501650        return fRc;
    16511651
     1652    def setVideoControllerType(self, eControllerType):
     1653        """
     1654        Set the video controller type of the VM.
     1655        Returns True on success and False on failure.  Error information is logged.
     1656        """
     1657        fRc = True;
     1658        try:
     1659            if self.fpApiVer >= 6.1 and hasattr(self.o.machine, 'graphicsAdapter'):
     1660                self.o.machine.graphicsAdapter.graphicsControllerType = eControllerType;
     1661            else:
     1662                self.o.machine.graphicsControllerType = eControllerType;
     1663        except:
     1664            reporter.errorXcpt('failed to set the video controller type of "%s" to %s' % (self.sName, eControllerType));
     1665            fRc = False;
     1666        else:
     1667            reporter.log('set the video controller type of "%s" to %s' % (self.sName, eControllerType));
     1668        self.oTstDrv.processPendingEvents();
     1669        return fRc;
     1670
     1671    def setAccelerate3DEnabled(self, fEnabled):
     1672        """
     1673        Set the video controller type of the VM.
     1674        Returns True on success and False on failure.  Error information is logged.
     1675        """
     1676        fRc = True;
     1677        try:
     1678            if self.fpApiVer >= 6.1 and hasattr(self.o.machine, 'graphicsAdapter'):
     1679                self.o.machine.graphicsAdapter.accelerate3DEnabled = fEnabled;
     1680            else:
     1681                self.o.machine.accelerate3DEnabled = fEnabled;
     1682        except:
     1683            reporter.errorXcpt('failed to set the accelerate3DEnabled of "%s" to %s' % (self.sName, fEnabled));
     1684            fRc = False;
     1685        else:
     1686            reporter.log('set the accelerate3DEnabled of "%s" to %s' % (self.sName, fEnabled));
     1687        self.oTstDrv.processPendingEvents();
     1688        return fRc;
     1689
    16521690    def setCpuCount(self, cCpus):
    16531691        """
Note: See TracChangeset for help on using the changeset viewer.

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