Merge branch 'master' into merge-master

# Conflicts:
#	AUTHORS
#	CHANGELOG.rst
#	_pytest/monkeypatch.py
#	_pytest/python.py
This commit is contained in:
Bruno Oliveira
2016-07-25 19:04:39 -03:00
18 changed files with 216 additions and 50 deletions

View File

@@ -121,6 +121,18 @@ class TestClass:
colitems = modcol.collect()
assert len(colitems) == 0
def test_issue1579_namedtuple(self, testdir):
testdir.makepyfile("""
import collections
TestCase = collections.namedtuple('TestCase', ['a'])
""")
result = testdir.runpytest('-rw')
result.stdout.fnmatch_lines(
"*cannot collect test class 'TestCase' "
"because it has a __new__ constructor*"
)
class TestGenerator:
def test_generative_functions(self, testdir):