Changeset 96558 in vbox
- Timestamp:
- Aug 30, 2022 6:26:47 PM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 153426
- Location:
- trunk/src/VBox/ValidationKit/testdriver
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/testdriver/reporter.py
r96555 r96558 965 965 finally: 966 966 g_oLock.acquire(); 967 elif sKind.startswith(' video/'):967 elif sKind.startswith('screenrecording/'): 968 968 self.log(0, '*** Uploading "%s" - KIND: "%s" - DESC: "%s" ***' 969 969 % (sSrcFilename, sKind, sDescription), sCaller, sTsPrf); -
trunk/src/VBox/ValidationKit/testdriver/vbox.py
r96556 r96558 902 902 self.fAlwaysUploadLogs = False; 903 903 self.fAlwaysUploadScreenshots = False; 904 self.fAlwaysUploadRecordings = False; # Only upload recording files on failure by default. 904 905 self.fEnableDebugger = True; 905 self.a RecordingFiles= [];906 self.adRecordingFiles = []; 906 907 self.fRecordingEnabled = False; # Don't record by default (yet). 907 908 self.fRecordingAudio = False; # Don't record audio by default. 908 self.fRecordingForceUpload = False; # Only upload recording files on failure by default.909 909 self.cSecsRecordingMax = 0; # No recording time limit in seconds. 910 910 self.cMbRecordingMax = 0; # No recording size limit in MiBs. … … 1800 1800 reporter.log(' --vbox-always-upload-screenshots'); 1801 1801 reporter.log(' Whether to always upload final screen shots, or only do so on failure.'); 1802 reporter.log(' --vbox-always-upload-recordings, --no-vbox-always-upload-recordings'); 1803 reporter.log(' Whether to always upload recordings, or only do so on failure.'); 1804 reporter.log(' Default: --no-vbox-always-upload-recordings'); 1802 1805 reporter.log(' --vbox-debugger, --no-vbox-debugger'); 1803 1806 reporter.log(' Enables the VBox debugger, port at 5000'); … … 1809 1812 reporter.log(' Enables/disables audio recording.'); 1810 1813 reporter.log(' Default: --no-vbox-recording-audio'); 1811 reporter.log(' --vbox-recording-force-upload, --no-vbox-recording-force-upload');1812 reporter.log(' Force uploading recordings or only upload them on test failure.');1813 reporter.log(' Default: --no-vbox-recording-force-upload');1814 1814 reporter.log(' --vbox-recording-max-time <seconds>'); 1815 1815 reporter.log(' Limits the maximum recording time in seconds.'); … … 1922 1922 elif asArgs[iArg] == '--vbox-always-upload-screenshots': 1923 1923 self.fAlwaysUploadScreenshots = True; 1924 elif asArgs[iArg] == '--no-vbox-always-upload-recordings': 1925 self.fAlwaysUploadRecordings = False; 1926 elif asArgs[iArg] == '--vbox-always-upload-recordings': 1927 self.fAlwaysUploadRecordings = True; 1924 1928 elif asArgs[iArg] == '--vbox-debugger': 1925 1929 self.fEnableDebugger = True; … … 1934 1938 elif asArgs[iArg] == '--vbox-recording-audio': 1935 1939 self.fRecordingAudio = True; 1936 elif asArgs[iArg] == '--no-vbox-recording-force-upload':1937 self.fRecordingForceUpload = False;1938 elif asArgs[iArg] == '--vbox-recording-force-upload':1939 self.fRecordingForceUpload = True;1940 1940 elif asArgs[iArg] == '--vbox-recording-max-time': 1941 1941 iArg += 1; … … 2564 2564 oScreen.filename = sRecFile; 2565 2565 sRecFile = oScreen.filename; # Get back the file from Main, in case it was modified somehow. 2566 oRecFile = { "id" : oScreen.id, "file": sRecFile };2567 self.a RecordingFiles.append(oRecFile);2566 dRecFile = { 'id' : oScreen.id, 'file' : sRecFile }; 2567 self.adRecordingFiles.append(dRecFile); 2568 2568 if self.fpApiVer >= 7.0: 2569 aFeatures = [ vboxcon.RecordingFeature_Video ];2569 aFeatures = [ vboxcon.RecordingFeature_Video, ]; 2570 2570 if self.fRecordingAudio: 2571 2571 aFeatures.append(vboxcon.RecordingFeature_Audio); … … 2579 2579 uFeatures = uFeatures | vboxcon.RecordingFeature_Audio; 2580 2580 oScreen.features = uFeatures; 2581 reporter.log2('Recording screen %d to "%s"' % ( oRecFile['id'], oRecFile['file']));2581 reporter.log2('Recording screen %d to "%s"' % (dRecFile['id'], dRecFile['file'],)); 2582 2582 oScreen.maxTime = self.cSecsRecordingMax; 2583 2583 oScreen.maxFileSize = self.cMbRecordingMax; … … 3439 3439 reporter.addLogFile(sLastScreenshotPath, 'screenshot/success', 'Last VM screenshot'); 3440 3440 3441 # Add produced recording files (if any) to the log files to be uploaded.3442 if reporter.testErrorCount() > 0 \3443 or self.fRecordingForceUpload: # By default we only upload WebM file on failures, to save some space.3444 for oRecFile in self.aRecordingFiles:3445 reporter.addLogFile(oRecFile['file'], 'video/webm', 'Recording of screen #%d' % (oRecFile['id'],));3446 3447 3441 # Add the guest OS log if it has been requested and taken successfully. 3448 3442 if sOsKernelLog is not None: … … 3482 3476 except: pass; # paranoia 3483 3477 3478 # Upload the screen video recordings if appropriate. 3479 if self.fAlwaysUploadRecordings or reporter.testErrorCount() > 0: 3480 for dRecFile in self.adRecordingFiles: 3481 reporter.addLogFile(dRecFile['file'], 3482 'screenrecording/failure' if reporter.testErrorCount() > 0 else 'screenrecording/success', 3483 'Recording of screen #%d' % (dRecFile['id'],)); 3484 3484 3485 3485 return fRc;
Note:
See TracChangeset
for help on using the changeset viewer.