Changeset 103521 in vbox
- Timestamp:
- Feb 22, 2024 10:20:39 AM (9 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/tests/audio/tdAudioTest.py
r103518 r103521 782 782 """ 783 783 784 self.logVmInfo(oVM);785 786 784 reporter.testStart("Audio Testing"); 787 785 … … 806 804 sVkatExe = self.getBinTool('vkat'); 807 805 808 # Now probe the backends. 806 # 807 # Probe the backends on the host. 808 # 809 809 reporter.testStart('VKAT Probing'); 810 810 asArgs = [ sVkatExe, 'enum', '--probe-backends' ]; 811 811 for _ in range(1, reporter.getVerbosity()): # Verbosity always is initialized at 1. 812 812 asArgs.extend([ '-v' ]); 813 fRc, iRc = self.executeHst("VKAT Host Audio Probing", asArgs);813 _, iRc = self.executeHst("VKAT Host Audio Probing", asArgs); 814 814 if iRc != 0: 815 815 # Not fatal, as VBox then should fall back to the NULL audio backend (also worth having as a test case). … … 819 819 reporter.testDone(); 820 820 821 # 821 822 # Reconfigure the VM. 823 # 824 fRc = True; 822 825 oSession = self.openSession(oVM); 823 826 if oSession is not None: … … 832 835 reporter.log('Set extradata: %s => %s' % (sKey, sValue)); 833 836 fRc = oSession.setExtraData(sKey, sValue) and fRc; 837 if not fRc: 838 break; 834 839 835 840 # Make sure that the VM's audio adapter is configured the way we need it to. 836 if self.fpApiVer >= 4.0: 841 if fRc \ 842 and self.fpApiVer >= 4.0: 837 843 enmAudioControllerType = None; 838 844 reporter.log('Configuring audio controller type ...'); … … 858 864 reporter.log('Enforcing audio controller type to HDA'); 859 865 860 reporter.log('Setting user-defined audio controller type to %d' % (enmAudioControllerType)); 861 oSession.setupAudio(enmAudioControllerType, 862 fEnable = True, fEnableIn = True, fEnableOut = True); 866 fRc = fRc and oSession.setupAudio(enmAudioControllerType, 867 fEnable = True, fEnableIn = True, fEnableOut = True); 863 868 864 869 # Save the settings. 865 870 fRc = fRc and oSession.saveSettings(); 866 871 fRc = oSession.close() and fRc; 867 868 reporter.testStart('Waiting for TXS'); 869 oSession, oTxsSession = self.startVmAndConnectToTxsViaTcp(oTestVm.sVmName, 870 fCdWait = True, 871 cMsTimeout = 3 * 60 * 1000, 872 sFileCdWait = '${OS/ARCH}/vkat${EXESUFF}'); 872 oSession = None; 873 874 self.logVmInfo(oVM); 875 876 else: 877 fRc = False; 878 879 if fRc: 880 reporter.testStart('Waiting for TXS'); 881 oSession, oTxsSession = self.startVmAndConnectToTxsViaTcp(oTestVm.sVmName, 882 fCdWait = True, 883 cMsTimeout = 3 * 60 * 1000, 884 sFileCdWait = '${OS/ARCH}/vkat${EXESUFF}'); 885 reporter.testDone(); 886 887 if oSession is not None: 888 889 self.prepareGuestForDebugging(oSession, oTxsSession, oTestVm); 890 891 reporter.log('Waiting for any OS startup sounds getting played (to skip those) ...'); 892 time.sleep(5); 893 894 self.addTask(oTxsSession); 895 896 fRc = self.doTest(oTestVm, oSession, oTxsSession); 897 898 # Cleanup. 899 self.removeTask(oTxsSession); 900 self.terminateVmBySession(oSession); 901 902 # Report an error in case we forgot it. 903 if not fRc: 904 reporter.error('Audio testing failed!'); 905 873 906 reporter.testDone(); 874 875 if oSession is not None:876 877 self.prepareGuestForDebugging(oSession, oTxsSession, oTestVm);878 879 reporter.log('Waiting for any OS startup sounds getting played (to skip those) ...');880 time.sleep(5);881 882 self.addTask(oTxsSession);883 884 fRc = self.doTest(oTestVm, oSession, oTxsSession);885 886 # Cleanup.887 self.removeTask(oTxsSession);888 self.terminateVmBySession(oSession);889 890 reporter.testDone(fSkip);891 907 return fRc; 892 908
Note:
See TracChangeset
for help on using the changeset viewer.