![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
Public Member Functions | |
__init__ (self, test_case) | |
__enter__ (self) | |
__exit__ (self, exc_type, exc_value, traceback) | |
options (self) | |
test_id (self) | |
working_dir (self) | |
IsResultSuppressed (self) | |
IsImageDiffSuppressed (self) | |
GetImageMatchingAlgorithm (self) | |
RunCommand (self, command, stdout=None) | |
GenerateAndTest (self, test_function) | |
Generate (self) | |
TestText (self) | |
TestPixel (self) | |
Public Attributes | |
test_case = test_case | |
test_result = None | |
int | duration_start = 0 |
source_dir | |
input_filename | |
pdf_path = os.path.join(self.working_dir, f'{self.test_id}.pdf') | |
actual_images = None | |
working_dir | |
Protected Member Functions | |
_RegenerateIfNeeded (self) | |
_VerifyEmptyText (self, txt_path) | |
_NewImageArtifact (self, *, image_path, md5_hash) | |
_CleanupPixelTest (self) | |
Runner for a single test case.
Definition at line 517 of file test_runner.py.
testing.tools.test_runner._TestCaseRunner.__init__ | ( | self, | |
test_case ) |
Definition at line 520 of file test_runner.py.
testing.tools.test_runner._TestCaseRunner.__enter__ | ( | self | ) |
Definition at line 530 of file test_runner.py.
References duration_start.
testing.tools.test_runner._TestCaseRunner.__exit__ | ( | self, | |
exc_type, | |||
exc_value, | |||
traceback ) |
Definition at line 534 of file test_runner.py.
References duration_start, test_case, and test_result.
|
protected |
Definition at line 813 of file test_runner.py.
References actual_images.
Referenced by TestPixel().
|
protected |
Definition at line 801 of file test_runner.py.
References ImageWithBindOptions.options, language::SignalSlot.options, PrintOut::Box.options, QAbstractFileIconEngine.options(), QAbstractFileIconProvider.options(), QAbstractFileIconProviderPrivate.options, QAbstractPrintDialogPrivate.options, QAuthenticator.options(), QAuthenticatorPrivate.options, QCocoaIntegration.options(), QColorDialog.options, QColorDialog.options(), QColorDialogOptionsPrivate.options, QColorDialogPrivate.options, QFileDialog.options, QFileDialog.options(), QFileDialogArgs.options, QFileDialogOptions.options(), QFileDialogOptionsPrivate.options, QFileDialogPrivate.options, QFileSystemModel.options, QFileSystemModel.options(), QFontDialog.options, QFontDialog.options(), QFontDialogOptions.options(), QFontDialogOptionsPrivate.options, QFontDialogPrivate.options, QInputDialog.options(), QMdiAreaPrivate.options, QMdiSubWindowPrivate.options, QMessageBox.options, QMessageBox.options(), QMessageBoxPrivate.options, QMessageDialogOptions.options(), QMessageDialogOptionsPrivate.options, QMinimalIntegration.options(), QOpenGLCachedTexture.options(), QPdfPageRendererPrivate::PageRequest.options, QPlatformColorDialogHelper.options(), QPlatformFileDialogHelper.options(), QPlatformFontDialogHelper.options(), QPlatformMessageDialogHelper.options(), QPrintDialog.options, QPrintDialog.options(), QPrintDialogPrivate.options, QQmlJS::Dom::AstDumper.options, QQmlJS::Dom::ConstantData.options(), QQmlJS::Dom::DomEnvironment.options(), QQmlJS::Dom::FormatPartialStatus.options, QQmlJS::Dom::LineWriter.options(), QQnxIntegration.options(), QQuickColorDialog.options, QQuickColorDialog.options(), QQuickColorDialogImpl.options(), QQuickColorDialogImplPrivate.options, QQuickFileDialog.options, QQuickFileDialog.options(), QQuickFileDialogImpl.options(), QQuickFileDialogImplPrivate.options, QQuickFileNameFilter.options(), QQuickFolderDialog.options, QQuickFolderDialog.options(), QQuickFolderDialogImpl.options(), QQuickFolderDialogImplPrivate.options, QQuickFontDialog.options, QQuickFontDialog.options(), QQuickFontDialogImpl.options(), QQuickFontDialogImplPrivate.options, QQuickMessageDialogImpl.options(), QQuickMessageDialogImplPrivate.options, QQuickPixmapKey.options, QSSGBufferManager::MeshData.options, QSSGQmlUtilities::OutputContext.options, QStorageIterator.options(), QSurfaceFormat.options(), QSvgHandler.options(), QSvgRenderer.options, QSvgRenderer.options(), QSvgRendererPrivate.options, QSvgTinyDocument.options(), QSvgWidget.options(), QWaylandKeymap.options, QWaylandKeymap.options(), QWindowsIntegration.options(), QWindowsOpenGLContextFormat.options, QWindowsTabletSupport.options(), QWizard.options, QWizard.options(), testing.tools.test_runner._PerProcessConfig.options, testing.tools.test_runner._PerProcessState.options, options(), and testing.tools.test_runner.TestRunner.options().
Referenced by TestPixel().
|
protected |
Definition at line 631 of file test_runner.py.
References input_filename, testing.tools.suppressor.Suppressor.IsImageDiffSuppressed(), IsImageDiffSuppressed(), testing.tools.suppressor.Suppressor.IsResultSuppressed(), IsResultSuppressed(), testing.tools.test_runner.TestRunner.IsResultSuppressed(), ImageWithBindOptions.options, language::SignalSlot.options, PrintOut::Box.options, QAbstractFileIconEngine.options(), QAbstractFileIconProvider.options(), QAbstractFileIconProviderPrivate.options, QAbstractPrintDialogPrivate.options, QAuthenticator.options(), QAuthenticatorPrivate.options, QCocoaIntegration.options(), QColorDialog.options, QColorDialog.options(), QColorDialogOptionsPrivate.options, QColorDialogPrivate.options, QFileDialog.options, QFileDialog.options(), QFileDialogArgs.options, QFileDialogOptions.options(), QFileDialogOptionsPrivate.options, QFileDialogPrivate.options, QFileSystemModel.options, QFileSystemModel.options(), QFontDialog.options, QFontDialog.options(), QFontDialogOptions.options(), QFontDialogOptionsPrivate.options, QFontDialogPrivate.options, QInputDialog.options(), QMdiAreaPrivate.options, QMdiSubWindowPrivate.options, QMessageBox.options, QMessageBox.options(), QMessageBoxPrivate.options, QMessageDialogOptions.options(), QMessageDialogOptionsPrivate.options, QMinimalIntegration.options(), QOpenGLCachedTexture.options(), QPdfPageRendererPrivate::PageRequest.options, QPlatformColorDialogHelper.options(), QPlatformFileDialogHelper.options(), QPlatformFontDialogHelper.options(), QPlatformMessageDialogHelper.options(), QPrintDialog.options, QPrintDialog.options(), QPrintDialogPrivate.options, QQmlJS::Dom::AstDumper.options, QQmlJS::Dom::ConstantData.options(), QQmlJS::Dom::DomEnvironment.options(), QQmlJS::Dom::FormatPartialStatus.options, QQmlJS::Dom::LineWriter.options(), QQnxIntegration.options(), QQuickColorDialog.options, QQuickColorDialog.options(), QQuickColorDialogImpl.options(), QQuickColorDialogImplPrivate.options, QQuickFileDialog.options, QQuickFileDialog.options(), QQuickFileDialogImpl.options(), QQuickFileDialogImplPrivate.options, QQuickFileNameFilter.options(), QQuickFolderDialog.options, QQuickFolderDialog.options(), QQuickFolderDialogImpl.options(), QQuickFolderDialogImplPrivate.options, QQuickFontDialog.options, QQuickFontDialog.options(), QQuickFontDialogImpl.options(), QQuickFontDialogImplPrivate.options, QQuickMessageDialogImpl.options(), QQuickMessageDialogImplPrivate.options, QQuickPixmapKey.options, QSSGBufferManager::MeshData.options, QSSGQmlUtilities::OutputContext.options, QStorageIterator.options(), QSurfaceFormat.options(), QSvgHandler.options(), QSvgRenderer.options, QSvgRenderer.options(), QSvgRendererPrivate.options, QSvgTinyDocument.options(), QSvgWidget.options(), QWaylandKeymap.options, QWaylandKeymap.options(), QWindowsIntegration.options(), QWindowsOpenGLContextFormat.options, QWindowsTabletSupport.options(), QWizard.options, QWizard.options(), testing.tools.test_runner._PerProcessConfig.options, testing.tools.test_runner._PerProcessState.options, options(), testing.tools.test_runner.TestRunner.options(), testing.tools.test_runner._PerProcessState.source_dir, and source_dir.
Referenced by TestPixel().
|
protected |
Definition at line 695 of file test_runner.py.
References open(), and test_case.
Referenced by TestText().
testing.tools.test_runner._TestCaseRunner.Generate | ( | self | ) |
Definition at line 642 of file test_runner.py.
References pdf_path, RunCommand(), testing.tools.test_runner._PerProcessState.source_dir, source_dir, and test_case.
Referenced by GenerateAndTest().
testing.tools.test_runner._TestCaseRunner.GenerateAndTest | ( | self, | |
test_function ) |
Generate test input and run pdfium_test.
Definition at line 623 of file test_runner.py.
References Config.Generate, CPP::WriteInitialization::Item::ItemData.Generate, and Generate().
testing.tools.test_runner._TestCaseRunner.GetImageMatchingAlgorithm | ( | self | ) |
Definition at line 561 of file test_runner.py.
References input_filename.
Referenced by TestPixel().
testing.tools.test_runner._TestCaseRunner.IsImageDiffSuppressed | ( | self | ) |
Definition at line 557 of file test_runner.py.
References input_filename.
Referenced by _RegenerateIfNeeded(), and TestPixel().
testing.tools.test_runner._TestCaseRunner.IsResultSuppressed | ( | self | ) |
Definition at line 553 of file test_runner.py.
References input_filename.
Referenced by _RegenerateIfNeeded(), and TestText().
testing.tools.test_runner._TestCaseRunner.options | ( | self | ) |
Definition at line 542 of file test_runner.py.
Referenced by _NewImageArtifact(), _RegenerateIfNeeded(), TestPixel(), and TestText().
testing.tools.test_runner._TestCaseRunner.RunCommand | ( | self, | |
command, | |||
stdout = None ) |
Runs a test command. Args: command: The list of command arguments. stdout: Optional `file`-like object to send standard output. Returns: The test result.
Definition at line 565 of file test_runner.py.
References test_case.
Referenced by Generate(), TestPixel(), and TestText().
testing.tools.test_runner._TestCaseRunner.test_id | ( | self | ) |
Definition at line 546 of file test_runner.py.
References test_case.
Referenced by testing.tools.test_runner.TestCase.NewResult().
testing.tools.test_runner._TestCaseRunner.TestPixel | ( | self | ) |
Definition at line 709 of file test_runner.py.
References _CleanupPixelTest(), _NewImageArtifact(), _RegenerateIfNeeded(), actual_images, testing.tools.suppressor.Suppressor.GetImageMatchingAlgorithm(), GetImageMatchingAlgorithm(), input_filename, testing.tools.suppressor.Suppressor.IsImageDiffSuppressed(), IsImageDiffSuppressed(), ImageWithBindOptions.options, language::SignalSlot.options, PrintOut::Box.options, QAbstractFileIconEngine.options(), QAbstractFileIconProvider.options(), QAbstractFileIconProviderPrivate.options, QAbstractPrintDialogPrivate.options, QAuthenticator.options(), QAuthenticatorPrivate.options, QCocoaIntegration.options(), QColorDialog.options, QColorDialog.options(), QColorDialogOptionsPrivate.options, QColorDialogPrivate.options, QFileDialog.options, QFileDialog.options(), QFileDialogArgs.options, QFileDialogOptions.options(), QFileDialogOptionsPrivate.options, QFileDialogPrivate.options, QFileSystemModel.options, QFileSystemModel.options(), QFontDialog.options, QFontDialog.options(), QFontDialogOptions.options(), QFontDialogOptionsPrivate.options, QFontDialogPrivate.options, QInputDialog.options(), QMdiAreaPrivate.options, QMdiSubWindowPrivate.options, QMessageBox.options, QMessageBox.options(), QMessageBoxPrivate.options, QMessageDialogOptions.options(), QMessageDialogOptionsPrivate.options, QMinimalIntegration.options(), QOpenGLCachedTexture.options(), QPdfPageRendererPrivate::PageRequest.options, QPlatformColorDialogHelper.options(), QPlatformFileDialogHelper.options(), QPlatformFontDialogHelper.options(), QPlatformMessageDialogHelper.options(), QPrintDialog.options, QPrintDialog.options(), QPrintDialogPrivate.options, QQmlJS::Dom::AstDumper.options, QQmlJS::Dom::ConstantData.options(), QQmlJS::Dom::DomEnvironment.options(), QQmlJS::Dom::FormatPartialStatus.options, QQmlJS::Dom::LineWriter.options(), QQnxIntegration.options(), QQuickColorDialog.options, QQuickColorDialog.options(), QQuickColorDialogImpl.options(), QQuickColorDialogImplPrivate.options, QQuickFileDialog.options, QQuickFileDialog.options(), QQuickFileDialogImpl.options(), QQuickFileDialogImplPrivate.options, QQuickFileNameFilter.options(), QQuickFolderDialog.options, QQuickFolderDialog.options(), QQuickFolderDialogImpl.options(), QQuickFolderDialogImplPrivate.options, QQuickFontDialog.options, QQuickFontDialog.options(), QQuickFontDialogImpl.options(), QQuickFontDialogImplPrivate.options, QQuickMessageDialogImpl.options(), QQuickMessageDialogImplPrivate.options, QQuickPixmapKey.options, QSSGBufferManager::MeshData.options, QSSGQmlUtilities::OutputContext.options, QStorageIterator.options(), QSurfaceFormat.options(), QSvgHandler.options(), QSvgRenderer.options, QSvgRenderer.options(), QSvgRendererPrivate.options, QSvgTinyDocument.options(), QSvgWidget.options(), QWaylandKeymap.options, QWaylandKeymap.options(), QWindowsIntegration.options(), QWindowsOpenGLContextFormat.options, QWindowsTabletSupport.options(), QWizard.options, QWizard.options(), testing.tools.test_runner._PerProcessConfig.options, testing.tools.test_runner._PerProcessState.options, options(), testing.tools.test_runner.TestRunner.options(), pdf_path, RunCommand(), testing.tools.test_runner._PerProcessState.source_dir, source_dir, testing.tools.test_runner._PerProcessState.working_dir, and working_dir.
testing.tools.test_runner._TestCaseRunner.TestText | ( | self | ) |
Definition at line 659 of file test_runner.py.
References _VerifyEmptyText(), testing.tools.suppressor.Suppressor.IsResultSuppressed(), IsResultSuppressed(), testing.tools.test_runner.TestRunner.IsResultSuppressed(), open(), ImageWithBindOptions.options, language::SignalSlot.options, PrintOut::Box.options, QAbstractFileIconEngine.options(), QAbstractFileIconProvider.options(), QAbstractFileIconProviderPrivate.options, QAbstractPrintDialogPrivate.options, QAuthenticator.options(), QAuthenticatorPrivate.options, QCocoaIntegration.options(), QColorDialog.options, QColorDialog.options(), QColorDialogOptionsPrivate.options, QColorDialogPrivate.options, QFileDialog.options, QFileDialog.options(), QFileDialogArgs.options, QFileDialogOptions.options(), QFileDialogOptionsPrivate.options, QFileDialogPrivate.options, QFileSystemModel.options, QFileSystemModel.options(), QFontDialog.options, QFontDialog.options(), QFontDialogOptions.options(), QFontDialogOptionsPrivate.options, QFontDialogPrivate.options, QInputDialog.options(), QMdiAreaPrivate.options, QMdiSubWindowPrivate.options, QMessageBox.options, QMessageBox.options(), QMessageBoxPrivate.options, QMessageDialogOptions.options(), QMessageDialogOptionsPrivate.options, QMinimalIntegration.options(), QOpenGLCachedTexture.options(), QPdfPageRendererPrivate::PageRequest.options, QPlatformColorDialogHelper.options(), QPlatformFileDialogHelper.options(), QPlatformFontDialogHelper.options(), QPlatformMessageDialogHelper.options(), QPrintDialog.options, QPrintDialog.options(), QPrintDialogPrivate.options, QQmlJS::Dom::AstDumper.options, QQmlJS::Dom::ConstantData.options(), QQmlJS::Dom::DomEnvironment.options(), QQmlJS::Dom::FormatPartialStatus.options, QQmlJS::Dom::LineWriter.options(), QQnxIntegration.options(), QQuickColorDialog.options, QQuickColorDialog.options(), QQuickColorDialogImpl.options(), QQuickColorDialogImplPrivate.options, QQuickFileDialog.options, QQuickFileDialog.options(), QQuickFileDialogImpl.options(), QQuickFileDialogImplPrivate.options, QQuickFileNameFilter.options(), QQuickFolderDialog.options, QQuickFolderDialog.options(), QQuickFolderDialogImpl.options(), QQuickFolderDialogImplPrivate.options, QQuickFontDialog.options, QQuickFontDialog.options(), QQuickFontDialogImpl.options(), QQuickFontDialogImplPrivate.options, QQuickMessageDialogImpl.options(), QQuickMessageDialogImplPrivate.options, QQuickPixmapKey.options, QSSGBufferManager::MeshData.options, QSSGQmlUtilities::OutputContext.options, QStorageIterator.options(), QSurfaceFormat.options(), QSvgHandler.options(), QSvgRenderer.options, QSvgRenderer.options(), QSvgRendererPrivate.options, QSvgTinyDocument.options(), QSvgWidget.options(), QWaylandKeymap.options, QWaylandKeymap.options(), QWindowsIntegration.options(), QWindowsOpenGLContextFormat.options, QWindowsTabletSupport.options(), QWizard.options, QWizard.options(), testing.tools.test_runner._PerProcessConfig.options, testing.tools.test_runner._PerProcessState.options, options(), testing.tools.test_runner.TestRunner.options(), pdf_path, RunCommand(), testing.tools.test_runner._PerProcessState.source_dir, source_dir, testing.tools.test_runner._PerProcessState.working_dir, and working_dir.
testing.tools.test_runner._TestCaseRunner.working_dir | ( | self | ) |
Definition at line 550 of file test_runner.py.
testing.tools.test_runner._TestCaseRunner.actual_images = None |
Definition at line 528 of file test_runner.py.
Referenced by _CleanupPixelTest(), and TestPixel().
int testing.tools.test_runner._TestCaseRunner.duration_start = 0 |
Definition at line 523 of file test_runner.py.
Referenced by __enter__(), and __exit__().
testing.tools.test_runner._TestCaseRunner.input_filename |
Definition at line 525 of file test_runner.py.
Referenced by _RegenerateIfNeeded(), GetImageMatchingAlgorithm(), IsImageDiffSuppressed(), IsResultSuppressed(), and TestPixel().
testing.tools.test_runner._TestCaseRunner.pdf_path = os.path.join(self.working_dir, f'{self.test_id}.pdf') |
Definition at line 527 of file test_runner.py.
Referenced by Generate(), TestPixel(), and TestText().
testing.tools.test_runner._TestCaseRunner.source_dir |
Definition at line 525 of file test_runner.py.
Referenced by _RegenerateIfNeeded(), Generate(), TestPixel(), and TestText().
testing.tools.test_runner._TestCaseRunner.test_case = test_case |
Definition at line 521 of file test_runner.py.
Referenced by __exit__(), _VerifyEmptyText(), Generate(), RunCommand(), and test_id().
testing.tools.test_runner._TestCaseRunner.test_result = None |
Definition at line 522 of file test_runner.py.
Referenced by __exit__().
testing.tools.test_runner._TestCaseRunner.working_dir |
Definition at line 639 of file test_runner.py.
Referenced by TestPixel(), and TestText().