tests: fix TypeErrors (#7038)

* tests: fix TypeError with test_mark_closest

It fails when trying to run it actually:

> TypeError: test_has_inherited() takes 0 positional arguments but 1 was given

* Fix testing/test_collection.py::TestCollector::test_getparent
This commit is contained in:
Daniel Hahler 2020-04-08 18:11:04 +02:00 committed by GitHub
parent 6356583eab
commit 4fd2623c12
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -53,8 +53,8 @@ class TestCollector:
def test_getparent(self, testdir): def test_getparent(self, testdir):
modcol = testdir.getmodulecol( modcol = testdir.getmodulecol(
""" """
class TestClass(object): class TestClass:
def test_foo(): def test_foo(self):
pass pass
""" """
) )

View File

@ -533,10 +533,10 @@ class TestFunctional:
@pytest.mark.c(location="class") @pytest.mark.c(location="class")
class Test: class Test:
@pytest.mark.c(location="function") @pytest.mark.c(location="function")
def test_has_own(): def test_has_own(self):
pass pass
def test_has_inherited(): def test_has_inherited(self):
pass pass
""" """