From 839c9361539aec8bf90a56cdea89ddccc8c40754 Mon Sep 17 00:00:00 2001 From: Ronny Pfannschmidt Date: Tue, 28 Feb 2017 17:30:52 +0100 Subject: [PATCH] _pytest.mark: fix unconfigure after bad configure, still potential bug --- _pytest/mark.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_pytest/mark.py b/_pytest/mark.py index ccc90d6e8..23ec44c29 100644 --- a/_pytest/mark.py +++ b/_pytest/mark.py @@ -229,7 +229,7 @@ def pytest_configure(config): def pytest_unconfigure(config): - MARK_GEN._config = config._old_mark_config + MARK_GEN._config = getattr(config, '_old_mark_config', None) class MarkGenerator(object):