From d43f0e1169a6204100025048635d310091cde9db Mon Sep 17 00:00:00 2001 From: Bill Little Date: Tue, 21 Feb 2023 11:53:13 +0000 Subject: [PATCH] code quality --- .pylintrc | 4 +++- src/geovista/qt.py | 1 + tests/test_qt.py | 11 +++++++---- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.pylintrc b/.pylintrc index 01db77cd..39915f2b 100644 --- a/.pylintrc +++ b/.pylintrc @@ -20,7 +20,9 @@ fail-on= fail-under=10.0 # Files or directories to be skipped. They should be base names, not paths. -ignore=CVS,_version.py +ignore=CVS, + _version.py, + CODE_OF_CONDUCT.md # Add files or directories matching the regex patterns to the ignore-list. The # regex matches against paths and can be in Posix or Windows format. diff --git a/src/geovista/qt.py b/src/geovista/qt.py index 8dde098d..05280aed 100644 --- a/src/geovista/qt.py +++ b/src/geovista/qt.py @@ -8,6 +8,7 @@ """ try: + # pylint: disable-next=import-outside-toplevel import pyvistaqt as pvqt except ImportError as e: e.msg = f'{e.msg} - please install the "pyvistaqt" and "pyqt" packages.' diff --git a/tests/test_qt.py b/tests/test_qt.py index 75f6d799..08966c9f 100644 --- a/tests/test_qt.py +++ b/tests/test_qt.py @@ -6,10 +6,13 @@ def test_import(): - # the test environment may or may not contain the "pyvistaqt" package. - # this test only checks that the expected exception is raised when it - # detects that the package is not already available in the test - # environment + """ + The test environment may or may not contain the "pyvistaqt" package. + This test only checks that the expected exception is raised when it + detects that the package is not already available in the test + environment. + + """ try: import pyvistaqt except ImportError: