From a309a571d9439b6330a0f0fa10e38ee43d061b12 Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Mon, 25 Jul 2016 08:16:32 +0200 Subject: [PATCH] Cleanups for #1763 --- CHANGELOG.rst | 2 +- _pytest/main.py | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index dd73fce5c..5cdb63470 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -21,7 +21,7 @@ e.g. with ``request.getfuncargvalue``. BACKWARD INCOMPAT: Previously these params were simply never defined. So a fixture decorated like ``@pytest.fixture(params=[0, 1, 2])`` only ran once. Now a failure is raised. Fixes (`#460`_). Thanks to - `@nikratio`_ for bug report, `@RedBeardCode`_ and `@tomviner`_ for PR. + `@nikratio`_ for bug report, `@RedBeardCode`_ and `@tomviner`_ for the PR. * Create correct diff for strings ending with newlines. Fixes (`#1553`_). Thanks `@Vogtinator`_ for reporting. Thanks to `@RedBeardCode`_ and diff --git a/_pytest/main.py b/_pytest/main.py index 7376c170f..31b52c503 100644 --- a/_pytest/main.py +++ b/_pytest/main.py @@ -94,9 +94,8 @@ def wrap_session(config, doit): excinfo = _pytest._code.ExceptionInfo() if initstate < 2 and isinstance( excinfo.value, pytest.exit.Exception): - excinfo = _pytest._code.ExceptionInfo() sys.stderr.write('{0}: {1}\n'.format( - type(excinfo.value).__name__, excinfo.value.msg)) + excinfo.typename, excinfo.value.msg)) config.hook.pytest_keyboard_interrupt(excinfo=excinfo) session.exitstatus = EXIT_INTERRUPTED except: