Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 500896 Details for
Bug 635810
dev-python/pytest-catchlog-1.2.2 : E and: u test_nothing_logged.py:7: AssertionError
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
dev-python:pytest-catchlog-1.2.2:20171029-165120.log
dev-python:pytest-catchlog-1.2.2:20171029-165120.log (text/plain), 42.64 KB, created by
Toralf Förster
on 2017-10-29 17:06:21 UTC
(
hide
)
Description:
dev-python:pytest-catchlog-1.2.2:20171029-165120.log
Filename:
MIME Type:
Creator:
Toralf Förster
Created:
2017-10-29 17:06:21 UTC
Size:
42.64 KB
patch
obsolete
> * Package: dev-python/pytest-catchlog-1.2.2 > * Repository: gentoo > * Maintainer: python@gentoo.org > * USE: abi_x86_64 amd64 elibc_glibc kernel_linux python_targets_python2_7 python_targets_python3_4 test userland_GNU > * FEATURES: network-sandbox preserve-libs sandbox test userpriv usersandbox >>>> Unpacking source... >>>> Unpacking pytest-catchlog-1.2.2.zip to /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work >>>> Source unpacked in /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work >>>> Preparing source in /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2 ... >>>> Source prepared. >>>> Configuring source in /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2 ... >>>> Source configured. >>>> Compiling source in /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2 ... > * python2_7: running distutils-r1_run_phase distutils-r1_python_compile >/usr/bin/python2.7 setup.py build >running build >running build_py >copying pytest_catchlog.py -> /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2-python2_7/lib >warning: build_py: byte-compiling is disabled, skipping. > > * python3_4: running distutils-r1_run_phase distutils-r1_python_compile >/usr/bin/python3.4 setup.py build >running build >running build_py >copying pytest_catchlog.py -> /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2-python3_4/lib >warning: build_py: byte-compiling is disabled, skipping. > >>>> Source compiled. >>>> Test phase: dev-python/pytest-catchlog-1.2.2 > * python2_7: running distutils-r1_run_phase python_test >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 -- /usr/bin/python2.7 >cachedir: .cache >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collecting ... collected 14 items > >test_pytest_catchlog.py::test_nothing_logged FAILED >test_pytest_catchlog.py::test_messages_logged PASSED >test_pytest_catchlog.py::test_setup_logging PASSED >test_pytest_catchlog.py::test_teardown_logging PASSED >test_pytest_catchlog.py::test_change_level FAILED >test_pytest_catchlog.py::test_with_statement FAILED >test_pytest_catchlog.py::test_log_access PASSED >test_pytest_catchlog.py::test_unicode PASSED >test_pytest_catchlog.py::test_funcarg_help PASSED >test_pytest_catchlog.py::test_record_tuples PASSED >test_pytest_catchlog.py::test_compat_camel_case_aliases FAILED >test_pytest_catchlog.py::test_compat_properties FAILED >test_pytest_catchlog.py::test_compat_records_modification PASSED >test_pytest_catchlog.py::test_disable_log_capturing FAILED > >=================================== FAILURES =================================== >_____________________________ test_nothing_logged ______________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_nothing_logged0')> > > def test_nothing_logged(testdir): > testdir.makepyfile(''' > import sys > import logging > > def test_foo(): > sys.stdout.write('text going to stdout') > sys.stderr.write('text going to stderr') > assert False > ''') > result = testdir.runpytest() > assert result.ret == 1 > result.stdout.fnmatch_lines(['*- Captured stdout call -*', > 'text going to stdout']) > result.stdout.fnmatch_lines(['*- Captured stderr call -*', > 'text going to stderr']) > py.test.raises(Exception, result.stdout.fnmatch_lines, >> ['*- Captured *log call -*']) >E Failed: nomatch: '*- Captured stdout call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_nothing_logged0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_nothing_logged.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u' def test_foo():' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_nothing_logged.py:7: AssertionError' >E fnmatch: '*- Captured stdout call -*' >E with: u'----------------------------- Captured stdout call -----------------------------' >E exact match: 'text going to stdout' >E nomatch: '*- Captured stderr call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_nothing_logged0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_nothing_logged.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u' def test_foo():' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_nothing_logged.py:7: AssertionError' >E and: u'----------------------------- Captured stdout call -----------------------------' >E and: u'text going to stdout' >E fnmatch: '*- Captured stderr call -*' >E with: u'----------------------------- Captured stderr call -----------------------------' >E exact match: 'text going to stderr' >E nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_nothing_logged0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_nothing_logged.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u' def test_foo():' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_nothing_logged.py:7: AssertionError' >E and: u'----------------------------- Captured stdout call -----------------------------' >E and: u'text going to stdout' >E and: u'----------------------------- Captured stderr call -----------------------------' >E and: u'text going to stderr' >E and: u'=========================== 1 failed in 0.06 seconds ===========================' >E and: u'' >E remains unmatched: '*- Captured *log call -*' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:27: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_nothing_logged0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_nothing_logged.py F > >=================================== FAILURES =================================== >___________________________________ test_foo ___________________________________ > > def test_foo(): > sys.stdout.write('text going to stdout') > sys.stderr.write('text going to stderr') >> assert False >E assert False > >test_nothing_logged.py:7: AssertionError >----------------------------- Captured stdout call ----------------------------- >text going to stdout >----------------------------- Captured stderr call ----------------------------- >text going to stderr >=========================== 1 failed in 0.06 seconds =========================== >______________________________ test_change_level _______________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_change_level0')> > > def test_change_level(testdir): > testdir.makepyfile(''' > import sys > import logging > > def test_foo(caplog): > caplog.set_level(logging.INFO) > log = logging.getLogger() > log.debug('handler DEBUG level') > log.info('handler INFO level') > > caplog.set_level(logging.CRITICAL, logger='root.baz') > log = logging.getLogger('root.baz') > log.warning('logger WARNING level') > log.critical('logger CRITICAL level') > > assert False > ''') > result = testdir.runpytest() > assert result.ret == 1 > result.stdout.fnmatch_lines(['*- Captured *log call -*', > '*handler INFO level*', > '*logger CRITICAL level*']) > py.test.raises(Exception, result.stdout.fnmatch_lines, >> ['*- Captured *log call -*', '*handler DEBUG level*']) >E Failed: nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_change_level0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_change_level.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3febc6a90>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u' caplog.set_level(logging.INFO)' >E and: u' log = logging.getLogger()' >E and: u" log.debug('handler DEBUG level')" >E and: u" log.info('handler INFO level')" >E and: u' ' >E and: u" caplog.set_level(logging.CRITICAL, logger='root.baz')" >E and: u" log = logging.getLogger('root.baz')" >E and: u" log.warning('logger WARNING level')" >E and: u" log.critical('logger CRITICAL level')" >E and: u' ' >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_change_level.py:15: AssertionError' >E fnmatch: '*- Captured *log call -*' >E with: u'------------------------------ Captured log call -------------------------------' >E fnmatch: '*handler INFO level*' >E with: u'test_change_level.py 8 INFO handler INFO level' >E fnmatch: '*logger CRITICAL level*' >E with: u'test_change_level.py 13 CRITICAL logger CRITICAL level' >E nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_change_level0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_change_level.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3febc6a90>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u' caplog.set_level(logging.INFO)' >E and: u' log = logging.getLogger()' >E and: u" log.debug('handler DEBUG level')" >E and: u" log.info('handler INFO level')" >E and: u' ' >E and: u" caplog.set_level(logging.CRITICAL, logger='root.baz')" >E and: u" log = logging.getLogger('root.baz')" >E and: u" log.warning('logger WARNING level')" >E and: u" log.critical('logger CRITICAL level')" >E and: u' ' >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_change_level.py:15: AssertionError' >E fnmatch: '*- Captured *log call -*' >E with: u'------------------------------ Captured log call -------------------------------' >E nomatch: '*handler DEBUG level*' >E and: u'test_change_level.py 8 INFO handler INFO level' >E and: u'test_change_level.py 13 CRITICAL logger CRITICAL level' >E and: u'=========================== 1 failed in 0.02 seconds ===========================' >E and: u'' >E remains unmatched: '*handler DEBUG level*' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:115: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_change_level0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_change_level.py F > >=================================== FAILURES =================================== >___________________________________ test_foo ___________________________________ > >caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3febc6a90> > > def test_foo(caplog): > caplog.set_level(logging.INFO) > log = logging.getLogger() > log.debug('handler DEBUG level') > log.info('handler INFO level') > > caplog.set_level(logging.CRITICAL, logger='root.baz') > log = logging.getLogger('root.baz') > log.warning('logger WARNING level') > log.critical('logger CRITICAL level') > >> assert False >E assert False > >test_change_level.py:15: AssertionError >------------------------------ Captured log call ------------------------------- >test_change_level.py 8 INFO handler INFO level >test_change_level.py 13 CRITICAL logger CRITICAL level >=========================== 1 failed in 0.02 seconds =========================== >------------------------------ Captured log call ------------------------------- >test_change_level.py 7 DEBUG handler DEBUG level >test_change_level.py 8 INFO handler INFO level >test_change_level.py 13 CRITICAL logger CRITICAL level >_____________________________ test_with_statement ______________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_with_statement0')> > > @py.test.mark.skipif('sys.version_info < (2,5)') > def test_with_statement(testdir): > testdir.makepyfile(''' > from __future__ import with_statement > import sys > import logging > > def test_foo(caplog): > with caplog.at_level(logging.INFO): > log = logging.getLogger() > log.debug('handler DEBUG level') > log.info('handler INFO level') > > with caplog.at_level(logging.CRITICAL, logger='root.baz'): > log = logging.getLogger('root.baz') > log.warning('logger WARNING level') > log.critical('logger CRITICAL level') > > assert False > ''') > result = testdir.runpytest() > assert result.ret == 1 > result.stdout.fnmatch_lines(['*- Captured *log call -*', > '*handler INFO level*', > '*logger CRITICAL level*']) > py.test.raises(Exception, result.stdout.fnmatch_lines, >> ['*- Captured *log call -*', '*handler DEBUG level*']) >E Failed: nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_with_statement0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_with_statement.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fec509d0>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u' with caplog.at_level(logging.INFO):' >E and: u' log = logging.getLogger()' >E and: u" log.debug('handler DEBUG level')" >E and: u" log.info('handler INFO level')" >E and: u' ' >E and: u" with caplog.at_level(logging.CRITICAL, logger='root.baz'):" >E and: u" log = logging.getLogger('root.baz')" >E and: u" log.warning('logger WARNING level')" >E and: u" log.critical('logger CRITICAL level')" >E and: u' ' >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_with_statement.py:16: AssertionError' >E fnmatch: '*- Captured *log call -*' >E with: u'------------------------------ Captured log call -------------------------------' >E fnmatch: '*handler INFO level*' >E with: u'test_with_statement.py 9 INFO handler INFO level' >E fnmatch: '*logger CRITICAL level*' >E with: u'test_with_statement.py 14 CRITICAL logger CRITICAL level' >E nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_with_statement0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_with_statement.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fec509d0>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u' with caplog.at_level(logging.INFO):' >E and: u' log = logging.getLogger()' >E and: u" log.debug('handler DEBUG level')" >E and: u" log.info('handler INFO level')" >E and: u' ' >E and: u" with caplog.at_level(logging.CRITICAL, logger='root.baz'):" >E and: u" log = logging.getLogger('root.baz')" >E and: u" log.warning('logger WARNING level')" >E and: u" log.critical('logger CRITICAL level')" >E and: u' ' >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_with_statement.py:16: AssertionError' >E fnmatch: '*- Captured *log call -*' >E with: u'------------------------------ Captured log call -------------------------------' >E nomatch: '*handler DEBUG level*' >E and: u'test_with_statement.py 9 INFO handler INFO level' >E and: u'test_with_statement.py 14 CRITICAL logger CRITICAL level' >E and: u'=========================== 1 failed in 0.02 seconds ===========================' >E and: u'' >E remains unmatched: '*handler DEBUG level*' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:146: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_with_statement0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_with_statement.py F > >=================================== FAILURES =================================== >___________________________________ test_foo ___________________________________ > >caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fec509d0> > > def test_foo(caplog): > with caplog.at_level(logging.INFO): > log = logging.getLogger() > log.debug('handler DEBUG level') > log.info('handler INFO level') > > with caplog.at_level(logging.CRITICAL, logger='root.baz'): > log = logging.getLogger('root.baz') > log.warning('logger WARNING level') > log.critical('logger CRITICAL level') > >> assert False >E assert False > >test_with_statement.py:16: AssertionError >------------------------------ Captured log call ------------------------------- >test_with_statement.py 9 INFO handler INFO level >test_with_statement.py 14 CRITICAL logger CRITICAL level >=========================== 1 failed in 0.02 seconds =========================== >------------------------------ Captured log call ------------------------------- >test_with_statement.py 8 DEBUG handler DEBUG level >test_with_statement.py 9 INFO handler INFO level >test_with_statement.py 14 CRITICAL logger CRITICAL level >________________________ test_compat_camel_case_aliases ________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_camel_case_aliases0')> > > def test_compat_camel_case_aliases(testdir): > testdir.makepyfile(''' > import logging > > def test_foo(caplog): > caplog.setLevel(logging.INFO) > logging.getLogger().debug('boo!') > > with caplog.atLevel(logging.WARNING): > logging.getLogger().info('catch me if you can') > ''') > result = testdir.runpytest() > assert result.ret == 0 > > py.test.raises(Exception, result.stdout.fnmatch_lines, >> ['*- Captured *log call -*']) >E Failed: nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_camel_case_aliases0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_compat_camel_case_aliases.py .' >E and: u'' >E and: u'=============================== warnings summary ===============================' >E and: u'test_compat_camel_case_aliases.py::test_foo' >E and: u" 'caplog.setLevel()' is deprecated, use 'caplog.set_level()' instead" >E and: u" 'caplog.atLevel()' is deprecated, use 'caplog.at_level()' instead" >E and: u'' >E and: u'-- Docs: http://doc.pytest.org/en/latest/warnings.html' >E and: u'===================== 1 passed, 2 warnings in 0.02 seconds =====================' >E and: u'' >E remains unmatched: '*- Captured *log call -*' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:222: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_camel_case_aliases0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_compat_camel_case_aliases.py . > >=============================== warnings summary =============================== >test_compat_camel_case_aliases.py::test_foo > 'caplog.setLevel()' is deprecated, use 'caplog.set_level()' instead > 'caplog.atLevel()' is deprecated, use 'caplog.at_level()' instead > >-- Docs: http://doc.pytest.org/en/latest/warnings.html >===================== 1 passed, 2 warnings in 0.02 seconds ===================== >------------------------------ Captured log call ------------------------------- >test_compat_camel_case_aliases.py 5 DEBUG boo! >test_compat_camel_case_aliases.py 8 INFO catch me if you can >____________________________ test_compat_properties ____________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_properties0')> > > def test_compat_properties(testdir): > testdir.makepyfile(''' > import logging > > def test_foo(caplog): > logging.getLogger().info('boo %s', 'arg') > > assert caplog.text == caplog.text() == str(caplog.text) > assert caplog.records == caplog.records() == list(caplog.records) > assert (caplog.record_tuples == > caplog.record_tuples() == list(caplog.record_tuples)) > ''') > result = testdir.runpytest() > assert result.ret == 0 > > result = testdir.runpytest('-rw') > assert result.ret == 0 > result.stdout.fnmatch_lines(''' > =*warning summary*= > *WL1*test_compat_properties*caplog.text()*deprecated* > *WL1*test_compat_properties*caplog.records()*deprecated* > *WL1*test_compat_properties*caplog.record_tuples()*deprecated* >> ''') >E Failed: nomatch: '=*warning summary*=' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_properties0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_compat_properties.py .' >E and: u'' >E and: u'=============================== warnings summary ===============================' >E and: u'test_compat_properties.py::test_foo' >E and: u" 'caplog.text()' syntax is deprecated, use 'caplog.text' property instead" >E and: u" 'caplog.records()' syntax is deprecated, use 'caplog.records' property instead" >E and: u" 'caplog.record_tuples()' syntax is deprecated, use 'caplog.record_tuples' property instead" >E and: u'' >E and: u'-- Docs: http://doc.pytest.org/en/latest/warnings.html' >E and: u'===================== 1 passed, 3 warnings in 0.02 seconds =====================' >E and: u'' >E remains unmatched: '=*warning summary*=' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:255: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_properties0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_compat_properties.py . > >=============================== warnings summary =============================== >test_compat_properties.py::test_foo > 'caplog.text()' syntax is deprecated, use 'caplog.text' property instead > 'caplog.records()' syntax is deprecated, use 'caplog.records' property instead > 'caplog.record_tuples()' syntax is deprecated, use 'caplog.record_tuples' property instead > >-- Docs: http://doc.pytest.org/en/latest/warnings.html >===================== 1 passed, 3 warnings in 0.02 seconds ===================== >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_compat_properties0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_compat_properties.py . > >=============================== warnings summary =============================== >test_compat_properties.py::test_foo > 'caplog.text()' syntax is deprecated, use 'caplog.text' property instead > 'caplog.records()' syntax is deprecated, use 'caplog.records' property instead > 'caplog.record_tuples()' syntax is deprecated, use 'caplog.record_tuples' property instead > >-- Docs: http://doc.pytest.org/en/latest/warnings.html >===================== 1 passed, 3 warnings in 0.02 seconds ===================== >------------------------------ Captured log call ------------------------------- >test_compat_properties.py 4 INFO boo arg >test_compat_properties.py 4 INFO boo arg >__________________________ test_disable_log_capturing __________________________ > >testdir = <Testdir local('/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_disable_log_capturing0')> > > def test_disable_log_capturing(testdir): > testdir.makepyfile(''' > import sys > import logging > > def test_foo(caplog): > sys.stdout.write('text going to stdout') > logging.getLogger().warning('catch me if you can!') > sys.stderr.write('text going to stderr') > assert False > ''') > result = testdir.runpytest('--no-print-logs') > print(result.stdout) > assert result.ret == 1 > result.stdout.fnmatch_lines(['*- Captured stdout call -*', > 'text going to stdout']) > result.stdout.fnmatch_lines(['*- Captured stderr call -*', > 'text going to stderr']) > py.test.raises(Exception, result.stdout.fnmatch_lines, >> ['*- Captured *log call -*']) >E Failed: nomatch: '*- Captured stdout call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_disable_log_capturing0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_disable_log_capturing.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fe896810>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" logging.getLogger().warning('catch me if you can!')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_disable_log_capturing.py:8: AssertionError' >E fnmatch: '*- Captured stdout call -*' >E with: u'----------------------------- Captured stdout call -----------------------------' >E exact match: 'text going to stdout' >E nomatch: '*- Captured stderr call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_disable_log_capturing0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_disable_log_capturing.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fe896810>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" logging.getLogger().warning('catch me if you can!')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_disable_log_capturing.py:8: AssertionError' >E and: u'----------------------------- Captured stdout call -----------------------------' >E and: u'text going to stdout' >E fnmatch: '*- Captured stderr call -*' >E with: u'----------------------------- Captured stderr call -----------------------------' >E exact match: 'text going to stderr' >E nomatch: '*- Captured *log call -*' >E and: u'============================= test session starts ==============================' >E and: u'platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0' >E and: u'rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_disable_log_capturing0, inifile:' >E and: u'plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3' >E and: u'collected 1 item' >E and: u'' >E and: u'test_disable_log_capturing.py F' >E and: u'' >E and: u'=================================== FAILURES ===================================' >E and: u'___________________________________ test_foo ___________________________________' >E and: u'' >E and: u'caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fe896810>' >E and: u'' >E and: u' def test_foo(caplog):' >E and: u" sys.stdout.write('text going to stdout')" >E and: u" logging.getLogger().warning('catch me if you can!')" >E and: u" sys.stderr.write('text going to stderr')" >E and: u'> assert False' >E and: u'E assert False' >E and: u'' >E and: u'test_disable_log_capturing.py:8: AssertionError' >E and: u'----------------------------- Captured stdout call -----------------------------' >E and: u'text going to stdout' >E and: u'----------------------------- Captured stderr call -----------------------------' >E and: u'text going to stderr' >E and: u'=========================== 1 failed in 0.02 seconds ===========================' >E and: u'' >E remains unmatched: '*- Captured *log call -*' > >../../../../../work/pytest-catchlog-1.2.2/test_pytest_catchlog.py:300: Failed >----------------------------- Captured stdout call ----------------------------- >============================= test session starts ============================== >platform linux2 -- Python 2.7.14, pytest-3.2.2, py-1.4.34, pluggy-0.4.0 >rootdir: /var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/pytest-of-portage/pytest-0/testdir/test_disable_log_capturing0, inifile: >plugins: catchlog-1.2.2, xdist-1.20.0, timeout-1.2.0, pep8-1.0.6, forked-0.2, cov-2.5.1, hypothesis-3.33.0, backports.unittest-mock-1.3 >collected 1 item > >test_disable_log_capturing.py F > >=================================== FAILURES =================================== >___________________________________ test_foo ___________________________________ > >caplog = <pytest_catchlog.CompatLogCaptureFixture object at 0x7fc3fe896810> > > def test_foo(caplog): > sys.stdout.write('text going to stdout') > logging.getLogger().warning('catch me if you can!') > sys.stderr.write('text going to stderr') >> assert False >E assert False > >test_disable_log_capturing.py:8: AssertionError >----------------------------- Captured stdout call ----------------------------- >text going to stdout >----------------------------- Captured stderr call ----------------------------- >text going to stderr >=========================== 1 failed in 0.02 seconds =========================== ><_pytest.pytester.LineMatcher instance at 0x7fc3fe7ca200> >------------------------------ Captured log call ------------------------------- >test_disable_log_capturing.py 6 WARNING catch me if you can! >====================== 6 failed, 8 passed in 1.64 seconds ====================== > * ERROR: dev-python/pytest-catchlog-1.2.2::gentoo failed (test phase): > * (no error message) > * > * Call stack: > * ebuild.sh, line 124: Called src_test > * environment, line 2686: Called distutils-r1_src_test > * environment, line 862: Called _distutils-r1_run_foreach_impl 'python_test' > * environment, line 308: Called python_foreach_impl 'distutils-r1_run_phase' 'python_test' > * environment, line 2210: Called multibuild_foreach_variant '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_test' > * environment, line 1516: Called _multibuild_run '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_test' > * environment, line 1514: Called _python_multibuild_wrapper 'distutils-r1_run_phase' 'python_test' > * environment, line 532: Called distutils-r1_run_phase 'python_test' > * environment, line 793: Called python_test > * environment, line 2566: Called die > * The specific snippet of code: > * PYTEST_PLUGINS=${PN/-/_} py.test -v -v test_pytest_catchlog.py || die > * > * If you need support, post the output of `emerge --info '=dev-python/pytest-catchlog-1.2.2::gentoo'`, > * the complete build log and the output of `emerge -pqv '=dev-python/pytest-catchlog-1.2.2::gentoo'`. > * The complete build log is located at '/var/log/portage/dev-python:pytest-catchlog-1.2.2:20171029-165120.log'. > * For convenience, a symlink to the build log is located at '/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/build.log'. > * The ebuild environment file is located at '/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/temp/environment'. > * Working directory: '/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2' > * S: '/var/tmp/portage/dev-python/pytest-catchlog-1.2.2/work/pytest-catchlog-1.2.2' > * Failed to kill pid(s) in '/sys/fs/cgroup/portage/dev-python:pytest-catchlog-1.2.2._fk1g81h/cgroup.procs': 24921
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 635810
:
500894
| 500896 |
500898
|
500900
|
500902
|
500904