pre-commit run pyupgrade --all-files

This commit is contained in:
Anthony Sottile
2019-06-02 15:32:00 -07:00
committed by Bruno Oliveira
parent 3f1ec520fc
commit a91fe1fedd
100 changed files with 739 additions and 801 deletions

View File

@@ -28,7 +28,7 @@ def assert_attr(node, **kwargs):
assert on_node == expected
class DomNode(object):
class DomNode:
def __init__(self, dom):
self.__node = dom
@@ -79,7 +79,7 @@ class DomNode(object):
return type(self)(self.__node.nextSibling)
class TestPython(object):
class TestPython:
def test_summing_simple(self, testdir):
testdir.makepyfile(
"""
@@ -696,7 +696,7 @@ def test_mangle_test_address():
def test_dont_configure_on_slaves(tmpdir):
gotten = []
class FakeConfig(object):
class FakeConfig:
def __init__(self):
self.pluginmanager = self
self.option = self
@@ -719,7 +719,7 @@ def test_dont_configure_on_slaves(tmpdir):
assert len(gotten) == 1
class TestNonPython(object):
class TestNonPython:
def test_summing_simple(self, testdir):
testdir.makeconftest(
"""
@@ -922,7 +922,7 @@ def test_double_colon_split_method_issue469(testdir):
def test_unicode_issue368(testdir):
path = testdir.tmpdir.join("test.xml")
log = LogXML(str(path), None)
ustr = u"ВНИ!"
ustr = "ВНИ!"
class Report(BaseReport):
longrepr = ustr
@@ -1166,13 +1166,13 @@ def test_fancy_items_regression(testdir):
pprint.pprint(items)
assert items == [
u"conftest a",
u"conftest a",
u"conftest b",
u"test_fancy_items_regression a",
u"test_fancy_items_regression a",
u"test_fancy_items_regression b",
u"test_fancy_items_regression test_pass",
"conftest a",
"conftest a",
"conftest b",
"test_fancy_items_regression a",
"test_fancy_items_regression a",
"test_fancy_items_regression b",
"test_fancy_items_regression test_pass",
]