modified pylint pragmas
This commit is contained in:
parent
af98f9a77d
commit
4862b2faf9
@ -496,6 +496,7 @@ def _init_modules(args, crash_handler):
|
|||||||
macros.init()
|
macros.init()
|
||||||
# Init backend-specific stuff
|
# Init backend-specific stuff
|
||||||
browsertab.init()
|
browsertab.init()
|
||||||
|
# pylint: enable=too-many-statements
|
||||||
|
|
||||||
|
|
||||||
class Quitter:
|
class Quitter:
|
||||||
|
@ -677,6 +677,7 @@ class AbstractTab(QWidget):
|
|||||||
|
|
||||||
self._install_event_filter()
|
self._install_event_filter()
|
||||||
self.zoom.set_default()
|
self.zoom.set_default()
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
def _install_event_filter(self):
|
def _install_event_filter(self):
|
||||||
raise NotImplementedError
|
raise NotImplementedError
|
||||||
|
@ -1515,6 +1515,7 @@ class CommandDispatcher:
|
|||||||
new_tab.data.viewing_source = True
|
new_tab.data.viewing_source = True
|
||||||
|
|
||||||
tab.dump_async(show_source_cb)
|
tab.dump_async(show_source_cb)
|
||||||
|
# pylint: enable=no-member
|
||||||
|
|
||||||
@cmdutils.register(instance='command-dispatcher', scope='window',
|
@cmdutils.register(instance='command-dispatcher', scope='window',
|
||||||
debug=True)
|
debug=True)
|
||||||
|
@ -239,6 +239,7 @@ class FileDownloadTarget(_DownloadTarget):
|
|||||||
def __init__(self, filename):
|
def __init__(self, filename):
|
||||||
# pylint: disable=super-init-not-called
|
# pylint: disable=super-init-not-called
|
||||||
self.filename = filename
|
self.filename = filename
|
||||||
|
# pylint: enable=super-init-not-called
|
||||||
|
|
||||||
def suggested_filename(self):
|
def suggested_filename(self):
|
||||||
return os.path.basename(self.filename)
|
return os.path.basename(self.filename)
|
||||||
@ -258,6 +259,7 @@ class FileObjDownloadTarget(_DownloadTarget):
|
|||||||
def __init__(self, fileobj):
|
def __init__(self, fileobj):
|
||||||
# pylint: disable=super-init-not-called
|
# pylint: disable=super-init-not-called
|
||||||
self.fileobj = fileobj
|
self.fileobj = fileobj
|
||||||
|
# pylint: enable=super-init-not-called
|
||||||
|
|
||||||
def suggested_filename(self):
|
def suggested_filename(self):
|
||||||
try:
|
try:
|
||||||
@ -285,6 +287,7 @@ class OpenFileDownloadTarget(_DownloadTarget):
|
|||||||
def __init__(self, cmdline=None):
|
def __init__(self, cmdline=None):
|
||||||
# pylint: disable=super-init-not-called
|
# pylint: disable=super-init-not-called
|
||||||
self.cmdline = cmdline
|
self.cmdline = cmdline
|
||||||
|
# pylint: enable=super-init-not-called
|
||||||
|
|
||||||
def suggested_filename(self):
|
def suggested_filename(self):
|
||||||
raise NoFilenameError
|
raise NoFilenameError
|
||||||
|
@ -393,6 +393,7 @@ class HintManager(QObject):
|
|||||||
# pylint: disable=not-an-iterable
|
# pylint: disable=not-an-iterable
|
||||||
for label in self._context.all_labels:
|
for label in self._context.all_labels:
|
||||||
label.cleanup()
|
label.cleanup()
|
||||||
|
# pylint: enable=not-an-iterable
|
||||||
|
|
||||||
text = self._get_text()
|
text = self._get_text()
|
||||||
message_bridge = objreg.get('message-bridge', scope='window',
|
message_bridge = objreg.get('message-bridge', scope='window',
|
||||||
@ -809,6 +810,7 @@ class HintManager(QObject):
|
|||||||
label.hide()
|
label.hide()
|
||||||
except webelem.Error:
|
except webelem.Error:
|
||||||
pass
|
pass
|
||||||
|
# pylint: enable=not-an-iterable
|
||||||
|
|
||||||
if not visible:
|
if not visible:
|
||||||
# Whoops, filtered all hints
|
# Whoops, filtered all hints
|
||||||
|
@ -254,6 +254,7 @@ class PACFetcher(QObject):
|
|||||||
def __eq__(self, other):
|
def __eq__(self, other):
|
||||||
# pylint: disable=protected-access
|
# pylint: disable=protected-access
|
||||||
return self._pac_url == other._pac_url
|
return self._pac_url == other._pac_url
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
return utils.get_repr(self, url=self._pac_url, constructor=True)
|
return utils.get_repr(self, url=self._pac_url, constructor=True)
|
||||||
|
@ -686,6 +686,7 @@ class WebEngineTab(browsertab.AbstractTab):
|
|||||||
try:
|
try:
|
||||||
# pylint: disable=no-member, useless-suppression
|
# pylint: disable=no-member, useless-suppression
|
||||||
sip.assign(authenticator, QAuthenticator())
|
sip.assign(authenticator, QAuthenticator())
|
||||||
|
# pylint: enable=no-member, useless-suppression
|
||||||
except AttributeError:
|
except AttributeError:
|
||||||
url_string = url.toDisplayString()
|
url_string = url.toDisplayString()
|
||||||
error_page = jinja.render(
|
error_page = jinja.render(
|
||||||
@ -705,6 +706,7 @@ class WebEngineTab(browsertab.AbstractTab):
|
|||||||
try:
|
try:
|
||||||
# pylint: disable=no-member, useless-suppression
|
# pylint: disable=no-member, useless-suppression
|
||||||
sip.assign(authenticator, QAuthenticator())
|
sip.assign(authenticator, QAuthenticator())
|
||||||
|
# pylint: enable=no-member, useless-suppression
|
||||||
except AttributeError:
|
except AttributeError:
|
||||||
# WORKAROUND for
|
# WORKAROUND for
|
||||||
# https://www.riverbankcomputing.com/pipermail/pyqt/2016-December/038400.html
|
# https://www.riverbankcomputing.com/pipermail/pyqt/2016-December/038400.html
|
||||||
|
@ -184,6 +184,7 @@ class WebView(QWebView):
|
|||||||
window=self.win_id)
|
window=self.win_id)
|
||||||
# pylint: disable=protected-access
|
# pylint: disable=protected-access
|
||||||
return tabbed_browser.tabopen(background=False)._widget
|
return tabbed_browser.tabopen(background=False)._widget
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
def paintEvent(self, e):
|
def paintEvent(self, e):
|
||||||
"""Extend paintEvent to emit a signal if the scroll position changed.
|
"""Extend paintEvent to emit a signal if the scroll position changed.
|
||||||
|
@ -100,6 +100,7 @@ class Command:
|
|||||||
if scope != 'global' and instance is None:
|
if scope != 'global' and instance is None:
|
||||||
raise ValueError("Setting scope without setting instance makes "
|
raise ValueError("Setting scope without setting instance makes "
|
||||||
"no sense!")
|
"no sense!")
|
||||||
|
# pylint: enable=too-many-locals
|
||||||
|
|
||||||
self.name = name
|
self.name = name
|
||||||
self.maxsplit = maxsplit
|
self.maxsplit = maxsplit
|
||||||
|
@ -59,6 +59,7 @@ class _QtFIFOReader(QObject):
|
|||||||
self._fifo = os.fdopen(fd, 'r')
|
self._fifo = os.fdopen(fd, 'r')
|
||||||
self._notifier = QSocketNotifier(fd, QSocketNotifier.Read, self)
|
self._notifier = QSocketNotifier(fd, QSocketNotifier.Read, self)
|
||||||
self._notifier.activated.connect(self.read_line)
|
self._notifier.activated.connect(self.read_line)
|
||||||
|
# pylint: enable=no-member,useless-suppression
|
||||||
|
|
||||||
@pyqtSlot()
|
@pyqtSlot()
|
||||||
def read_line(self):
|
def read_line(self):
|
||||||
@ -247,6 +248,7 @@ class _POSIXUserscriptRunner(_BaseUserscriptRunner):
|
|||||||
dir=standarddir.runtime())
|
dir=standarddir.runtime())
|
||||||
# pylint: disable=no-member,useless-suppression
|
# pylint: disable=no-member,useless-suppression
|
||||||
os.mkfifo(self._filepath)
|
os.mkfifo(self._filepath)
|
||||||
|
# pylint: enable=no-member,useless-suppression
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
message.error("Error while creating FIFO: {}".format(e))
|
message.error("Error while creating FIFO: {}".format(e))
|
||||||
return
|
return
|
||||||
|
@ -154,6 +154,7 @@ class CompletionModel(QAbstractItemModel):
|
|||||||
"""Override QAbstractItemModel::columnCount."""
|
"""Override QAbstractItemModel::columnCount."""
|
||||||
# pylint: disable=unused-argument
|
# pylint: disable=unused-argument
|
||||||
return 3
|
return 3
|
||||||
|
# pylint: enable=unused-argument
|
||||||
|
|
||||||
def canFetchMore(self, parent):
|
def canFetchMore(self, parent):
|
||||||
"""Override to forward the call to the categories."""
|
"""Override to forward the call to the categories."""
|
||||||
|
@ -287,6 +287,7 @@ def _try_import_backends():
|
|||||||
assert results.webengine_error is not None
|
assert results.webengine_error is not None
|
||||||
|
|
||||||
return results
|
return results
|
||||||
|
# pylint: enable=unused-variable
|
||||||
|
|
||||||
|
|
||||||
def _handle_ssl_support(fatal=False):
|
def _handle_ssl_support(fatal=False):
|
||||||
|
@ -48,6 +48,7 @@ def check_python_version():
|
|||||||
# still has < 2.6 installed.
|
# still has < 2.6 installed.
|
||||||
# pylint: disable=bad-builtin
|
# pylint: disable=bad-builtin
|
||||||
version_str = '.'.join(map(str, sys.version_info[:3]))
|
version_str = '.'.join(map(str, sys.version_info[:3]))
|
||||||
|
# pylint: enable=bad-builtin
|
||||||
text = ("At least Python 3.5 is required to run qutebrowser, but " +
|
text = ("At least Python 3.5 is required to run qutebrowser, but " +
|
||||||
"it's running with " + version_str + ".\n")
|
"it's running with " + version_str + ".\n")
|
||||||
if Tk and '--no-err-windows' not in sys.argv: # pragma: no cover
|
if Tk and '--no-err-windows' not in sys.argv: # pragma: no cover
|
||||||
|
@ -323,6 +323,7 @@ class SignalHandler(QObject):
|
|||||||
self)
|
self)
|
||||||
self._notifier.activated.connect(self.handle_signal_wakeup)
|
self._notifier.activated.connect(self.handle_signal_wakeup)
|
||||||
self._orig_wakeup_fd = signal.set_wakeup_fd(write_fd)
|
self._orig_wakeup_fd = signal.set_wakeup_fd(write_fd)
|
||||||
|
# pylint: enable=import-error,no-member,useless-suppression
|
||||||
else:
|
else:
|
||||||
self._timer.start(1000)
|
self._timer.start(1000)
|
||||||
self._timer.timeout.connect(lambda: None)
|
self._timer.timeout.connect(lambda: None)
|
||||||
|
@ -127,6 +127,7 @@ def init_faulthandler(fileobj=sys.__stderr__):
|
|||||||
# If available, we also want a traceback on SIGUSR1.
|
# If available, we also want a traceback on SIGUSR1.
|
||||||
# pylint: disable=no-member,useless-suppression
|
# pylint: disable=no-member,useless-suppression
|
||||||
faulthandler.register(signal.SIGUSR1)
|
faulthandler.register(signal.SIGUSR1)
|
||||||
|
# pylint: enable=no-member,useless-suppression
|
||||||
|
|
||||||
|
|
||||||
def check_pyqt_core():
|
def check_pyqt_core():
|
||||||
@ -186,6 +187,7 @@ def check_ssl_support():
|
|||||||
from PyQt5.QtNetwork import QSslSocket
|
from PyQt5.QtNetwork import QSslSocket
|
||||||
except ImportError:
|
except ImportError:
|
||||||
_die("Fatal error: Your Qt is built without SSL support.")
|
_die("Fatal error: Your Qt is built without SSL support.")
|
||||||
|
# pylint: enable=unused-variable
|
||||||
|
|
||||||
|
|
||||||
def _check_modules(modules):
|
def _check_modules(modules):
|
||||||
|
@ -119,6 +119,7 @@ class ShellLexer:
|
|||||||
self.token += nextchar
|
self.token += nextchar
|
||||||
else:
|
else:
|
||||||
raise AssertionError("Invalid state {!r}!".format(self.state))
|
raise AssertionError("Invalid state {!r}!".format(self.state))
|
||||||
|
# pylint: enable=too-many-branches,too-many-statements
|
||||||
if self.state in self.escape and not self.keep:
|
if self.state in self.escape and not self.keep:
|
||||||
self.token += self.state
|
self.token += self.state
|
||||||
if self.token or self.quoted:
|
if self.token or self.quoted:
|
||||||
|
@ -171,6 +171,7 @@ def debug_cache_stats():
|
|||||||
prefix_info = configdata.is_valid_prefix.cache_info()
|
prefix_info = configdata.is_valid_prefix.cache_info()
|
||||||
# pylint: disable=protected-access
|
# pylint: disable=protected-access
|
||||||
render_stylesheet_info = config._render_stylesheet.cache_info()
|
render_stylesheet_info = config._render_stylesheet.cache_info()
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
history_info = None
|
history_info = None
|
||||||
try:
|
try:
|
||||||
|
@ -109,6 +109,7 @@ def vdebug(self, msg, *args, **kwargs):
|
|||||||
if self.isEnabledFor(VDEBUG_LEVEL):
|
if self.isEnabledFor(VDEBUG_LEVEL):
|
||||||
# pylint: disable=protected-access
|
# pylint: disable=protected-access
|
||||||
self._log(VDEBUG_LEVEL, msg, args, **kwargs)
|
self._log(VDEBUG_LEVEL, msg, args, **kwargs)
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
|
|
||||||
logging.Logger.vdebug = vdebug
|
logging.Logger.vdebug = vdebug
|
||||||
|
@ -182,6 +182,7 @@ class AsciiDoc:
|
|||||||
|
|
||||||
asciidoc_args = ['--theme=qute', '-a toc', '-a toc-placement=manual']
|
asciidoc_args = ['--theme=qute', '-a toc', '-a toc-placement=manual']
|
||||||
self.call(modified_src, dst, *asciidoc_args)
|
self.call(modified_src, dst, *asciidoc_args)
|
||||||
|
# pylint: enable=too-many-locals,too-many-statements
|
||||||
|
|
||||||
def _build_website(self):
|
def _build_website(self):
|
||||||
"""Prepare and build the website."""
|
"""Prepare and build the website."""
|
||||||
|
@ -162,6 +162,7 @@ def _get_configtypes():
|
|||||||
configtypes._Numeric] and
|
configtypes._Numeric] and
|
||||||
issubclass(e, configtypes.BaseType))
|
issubclass(e, configtypes.BaseType))
|
||||||
yield from inspect.getmembers(configtypes, predicate)
|
yield from inspect.getmembers(configtypes, predicate)
|
||||||
|
# pylint: enable=protected-access
|
||||||
|
|
||||||
|
|
||||||
def _get_setting_types_quickref():
|
def _get_setting_types_quickref():
|
||||||
@ -500,6 +501,7 @@ def regenerate_manpage(filename):
|
|||||||
"""Update manpage OPTIONS using an argparse parser."""
|
"""Update manpage OPTIONS using an argparse parser."""
|
||||||
# pylint: disable=protected-access
|
# pylint: disable=protected-access
|
||||||
parser = qutebrowser.get_argparser()
|
parser = qutebrowser.get_argparser()
|
||||||
|
# pylint: enable=protected-access
|
||||||
groups = []
|
groups = []
|
||||||
# positionals, optionals and user-defined groups
|
# positionals, optionals and user-defined groups
|
||||||
for group in parser._action_groups:
|
for group in parser._action_groups:
|
||||||
|
@ -73,6 +73,7 @@ def filter_list(complete_list, browsers):
|
|||||||
if found:
|
if found:
|
||||||
break
|
break
|
||||||
return table
|
return table
|
||||||
|
# pylint: enable=too-many-nested-blocks
|
||||||
|
|
||||||
|
|
||||||
def add_diversity(table):
|
def add_diversity(table):
|
||||||
|
@ -172,6 +172,7 @@ def pytest_configure(config):
|
|||||||
# pylint: disable=unused-variable
|
# pylint: disable=unused-variable
|
||||||
if config.webengine:
|
if config.webengine:
|
||||||
import PyQt5.QtWebEngineWidgets
|
import PyQt5.QtWebEngineWidgets
|
||||||
|
# pylint: enable=unused-variable
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture(scope='session', autouse=True)
|
@pytest.fixture(scope='session', autouse=True)
|
||||||
|
@ -23,6 +23,7 @@ import pytest_bdd as bdd
|
|||||||
|
|
||||||
# pylint: disable=unused-import
|
# pylint: disable=unused-import
|
||||||
from end2end.features.test_yankpaste_bdd import init_fake_clipboard
|
from end2end.features.test_yankpaste_bdd import init_fake_clipboard
|
||||||
|
# pylint: enable=unused-import
|
||||||
|
|
||||||
|
|
||||||
@bdd.then(bdd.parsers.parse('"{text}" should be found'))
|
@bdd.then(bdd.parsers.parse('"{text}" should be found'))
|
||||||
|
@ -80,6 +80,7 @@ class Request(testprocess.Line):
|
|||||||
|
|
||||||
'/500-inline': [http.client.INTERNAL_SERVER_ERROR],
|
'/500-inline': [http.client.INTERNAL_SERVER_ERROR],
|
||||||
}
|
}
|
||||||
|
# pylint: enable=no-member
|
||||||
for i in range(15):
|
for i in range(15):
|
||||||
path_to_statuses['/redirect/{}'.format(i)] = [http.client.FOUND]
|
path_to_statuses['/redirect/{}'.format(i)] = [http.client.FOUND]
|
||||||
for suffix in ['', '1', '2', '3', '4', '5', '6']:
|
for suffix in ['', '1', '2', '3', '4', '5', '6']:
|
||||||
|
@ -208,3 +208,4 @@ def test_enter_folder(dir_layout, quteproc, folder):
|
|||||||
assert foldernames == folders
|
assert foldernames == folders
|
||||||
filenames = [item.text for item in page.files]
|
filenames = [item.text for item in page.files]
|
||||||
assert filenames == files
|
assert filenames == files
|
||||||
|
# pylint: enable=not-an-iterable
|
||||||
|
@ -137,6 +137,7 @@ def fake_statusbar(qtbot):
|
|||||||
# pylint: disable=attribute-defined-outside-init
|
# pylint: disable=attribute-defined-outside-init
|
||||||
statusbar.container = container
|
statusbar.container = container
|
||||||
vbox.addWidget(statusbar)
|
vbox.addWidget(statusbar)
|
||||||
|
# pylint: enable=attribute-defined-outside-init
|
||||||
|
|
||||||
with qtbot.waitExposed(container):
|
with qtbot.waitExposed(container):
|
||||||
container.show()
|
container.show()
|
||||||
|
@ -91,6 +91,8 @@ class Tab(browsertab.AbstractTab):
|
|||||||
def _install_event_filter(self):
|
def _install_event_filter(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
# pylint: enable=abstract-method
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.xfail(run=False, reason='Causes segfaults, see #1638')
|
@pytest.mark.xfail(run=False, reason='Causes segfaults, see #1638')
|
||||||
def test_tab(qtbot, view, config_stub, tab_registry, mode_manager):
|
def test_tab(qtbot, view, config_stub, tab_registry, mode_manager):
|
||||||
|
@ -94,6 +94,8 @@ def _pac_noexcept_test(call):
|
|||||||
("known.domain", "'1.2.3.4'"),
|
("known.domain", "'1.2.3.4'"),
|
||||||
("bogus.domain.foobar", "null")
|
("bogus.domain.foobar", "null")
|
||||||
])
|
])
|
||||||
|
# pylint: enable=line-too-long, invalid-name
|
||||||
|
|
||||||
def test_dnsResolve(monkeypatch, domain, expected):
|
def test_dnsResolve(monkeypatch, domain, expected):
|
||||||
def mock_fromName(host):
|
def mock_fromName(host):
|
||||||
info = QHostInfo()
|
info = QHostInfo()
|
||||||
|
@ -130,6 +130,7 @@ def get_webelem(geometry=None, frame=None, *, null=False, style=None,
|
|||||||
elem.styleProperty.side_effect = _style_property
|
elem.styleProperty.side_effect = _style_property
|
||||||
wrapped = webkitelem.WebKitElement(elem, tab=None)
|
wrapped = webkitelem.WebKitElement(elem, tab=None)
|
||||||
return wrapped
|
return wrapped
|
||||||
|
# pylint: enable=too-many-locals,too-many-branches
|
||||||
|
|
||||||
|
|
||||||
class SelectionAndFilterTests:
|
class SelectionAndFilterTests:
|
||||||
|
@ -112,6 +112,7 @@ class TestYaml:
|
|||||||
assert ' colors.hints.fg: magenta' in lines
|
assert ' colors.hints.fg: magenta' in lines
|
||||||
if insert:
|
if insert:
|
||||||
assert ' tabs.show: never' in lines
|
assert ' tabs.show: never' in lines
|
||||||
|
# pylint: enable=superfluous-parens
|
||||||
|
|
||||||
def test_init_save_manager(self, yaml, fake_save_manager):
|
def test_init_save_manager(self, yaml, fake_save_manager):
|
||||||
yaml.init_save_manager(fake_save_manager)
|
yaml.init_save_manager(fake_save_manager)
|
||||||
@ -404,6 +405,7 @@ class TestConfigPy:
|
|||||||
"""Test whether getting options works correctly."""
|
"""Test whether getting options works correctly."""
|
||||||
# pylint: disable=bad-config-option
|
# pylint: disable=bad-config-option
|
||||||
config.val.colors.hints.fg = 'green'
|
config.val.colors.hints.fg = 'green'
|
||||||
|
# pylint: enable=bad-config-option
|
||||||
if set_first:
|
if set_first:
|
||||||
confpy.write('c.colors.hints.fg = "red"',
|
confpy.write('c.colors.hints.fg = "red"',
|
||||||
'assert {} == "red"'.format(get_line))
|
'assert {} == "red"'.format(get_line))
|
||||||
|
@ -177,6 +177,7 @@ class TestEarlyInit:
|
|||||||
assert config.instance._values == {}
|
assert config.instance._values == {}
|
||||||
else:
|
else:
|
||||||
assert config.instance._values == {'colors.hints.fg': 'magenta'}
|
assert config.instance._values == {'colors.hints.fg': 'magenta'}
|
||||||
|
# pylint: enable=too-many-locals,too-many-branches
|
||||||
|
|
||||||
def test_invalid_change_filter(self, init_patch, args):
|
def test_invalid_change_filter(self, init_patch, args):
|
||||||
config.change_filter('foobar')
|
config.change_filter('foobar')
|
||||||
|
@ -311,6 +311,7 @@ class TestListen:
|
|||||||
sockdir, dir_stat.st_uid, dir_stat.st_mode))
|
sockdir, dir_stat.st_uid, dir_stat.st_mode))
|
||||||
print('sockfile: {} / owner {} / mode {:o}'.format(
|
print('sockfile: {} / owner {} / mode {:o}'.format(
|
||||||
sockfile, file_stat.st_uid, file_stat.st_mode))
|
sockfile, file_stat.st_uid, file_stat.st_mode))
|
||||||
|
# pylint: enable=no-member,useless-suppression
|
||||||
|
|
||||||
assert file_owner_ok or dir_owner_ok
|
assert file_owner_ok or dir_owner_ok
|
||||||
assert file_mode_ok or dir_mode_ok
|
assert file_mode_ok or dir_mode_ok
|
||||||
|
@ -267,6 +267,7 @@ class TestGetAllObjects:
|
|||||||
|
|
||||||
global object registry - 0 objects:
|
global object registry - 0 objects:
|
||||||
""").rstrip('\n')
|
""").rstrip('\n')
|
||||||
|
# pylint: enable=unused-variable
|
||||||
|
|
||||||
assert debug.get_all_objects(start_obj=root) == expected
|
assert debug.get_all_objects(start_obj=root) == expected
|
||||||
|
|
||||||
|
@ -27,6 +27,7 @@ import unittest.mock
|
|||||||
try:
|
try:
|
||||||
# pylint: disable=no-name-in-module,useless-suppression
|
# pylint: disable=no-name-in-module,useless-suppression
|
||||||
from test import test_file
|
from test import test_file
|
||||||
|
# pylint: enable=no-name-in-module,useless-suppression
|
||||||
except ImportError:
|
except ImportError:
|
||||||
# Debian patches Python to remove the tests...
|
# Debian patches Python to remove the tests...
|
||||||
test_file = None
|
test_file = None
|
||||||
@ -706,6 +707,7 @@ class TestPyQIODevice:
|
|||||||
pyqiodev.open(QIODevice.ReadOnly)
|
pyqiodev.open(QIODevice.ReadOnly)
|
||||||
with pytest.raises(io.UnsupportedOperation):
|
with pytest.raises(io.UnsupportedOperation):
|
||||||
pyqiodev.seek(0, whence)
|
pyqiodev.seek(0, whence)
|
||||||
|
# pylint: enable=no-member,useless-suppression
|
||||||
|
|
||||||
@pytest.mark.flaky()
|
@pytest.mark.flaky()
|
||||||
def test_qprocess(self, py_proc):
|
def test_qprocess(self, py_proc):
|
||||||
@ -905,3 +907,4 @@ class TestEventLoop:
|
|||||||
QTimer.singleShot(400, self.loop.quit)
|
QTimer.singleShot(400, self.loop.quit)
|
||||||
self.loop.exec_()
|
self.loop.exec_()
|
||||||
assert not self.loop._executing
|
assert not self.loop._executing
|
||||||
|
# pylint: enable=attribute-defined-outside-init
|
||||||
|
Loading…
Reference in New Issue
Block a user