Mock Version: 2.9 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target x86_64 --nodeps /builddir/build/SPECS/python-TestSlide.spec'], chrootPath='/var/lib/mock/fedora-rawhide-x86_64-1611935249.799321/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=0uid=1001gid=135user='mockbuild'nspawn_args=['--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11']unshare_net=TrueprintOutput=True) Using nspawn with args ['--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11'] Executing command: ['/usr/bin/systemd-nspawn', '-q', '-M', 'b14670d77b7b4f3098ab8e48800aaacf', '-D', '/var/lib/mock/fedora-rawhide-x86_64-1611935249.799321/root', '-a', '-u', 'mockbuild', '--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11', '--console=pipe', '--setenv=TERM=vt100', '--setenv=SHELL=/bin/bash', '--setenv=HOME=/builddir', '--setenv=HOSTNAME=mock', '--setenv=PATH=/usr/bin:/bin:/usr/sbin:/sbin', '--setenv=PROMPT_COMMAND=printf "\\033]0;\\007"', '--setenv=PS1= \\s-\\v\\$ ', '--setenv=LANG=C.UTF-8', '--resolv-conf=off', 'bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target x86_64 --nodeps /builddir/build/SPECS/python-TestSlide.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8', 'SYSTEMD_NSPAWN_TMPFS_TMP': '0'} and shell False Building target platforms: x86_64 Building for target x86_64 setting SOURCE_DATE_EPOCH=1609804800 Wrote: /builddir/build/SRPMS/python-TestSlide-2.6.4-2.fc34.src.rpm Child return code was: 0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/python-TestSlide.spec'], chrootPath='/var/lib/mock/fedora-rawhide-x86_64-1611935249.799321/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=0uid=1001gid=135user='mockbuild'nspawn_args=['--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11']unshare_net=TrueprintOutput=True) Using nspawn with args ['--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11'] Executing command: ['/usr/bin/systemd-nspawn', '-q', '-M', 'fa78e14e8da04d6089b9920a341c2403', '-D', '/var/lib/mock/fedora-rawhide-x86_64-1611935249.799321/root', '-a', '-u', 'mockbuild', '--capability=cap_ipc_lock', '--rlimit=RLIMIT_NOFILE=10240', '--capability=cap_ipc_lock', '--bind=/tmp/mock-resolv.anav7en1:/etc/resolv.conf', '--bind=/dev/btrfs-control', '--bind=/dev/loop-control', '--bind=/dev/loop0', '--bind=/dev/loop1', '--bind=/dev/loop2', '--bind=/dev/loop3', '--bind=/dev/loop4', '--bind=/dev/loop5', '--bind=/dev/loop6', '--bind=/dev/loop7', '--bind=/dev/loop8', '--bind=/dev/loop9', '--bind=/dev/loop10', '--bind=/dev/loop11', '--console=pipe', '--setenv=TERM=vt100', '--setenv=SHELL=/bin/bash', '--setenv=HOME=/builddir', '--setenv=HOSTNAME=mock', '--setenv=PATH=/usr/bin:/bin:/usr/sbin:/sbin', '--setenv=PROMPT_COMMAND=printf "\\033]0;\\007"', '--setenv=PS1= \\s-\\v\\$ ', '--setenv=LANG=C.UTF-8', '--resolv-conf=off', 'bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target x86_64 --nodeps /builddir/build/SPECS/python-TestSlide.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8', 'SYSTEMD_NSPAWN_TMPFS_TMP': '0'} and shell False Building target platforms: x86_64 Building for target x86_64 setting SOURCE_DATE_EPOCH=1609804800 Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.jP9t2T + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf TestSlide-2.6.4 + /usr/bin/gzip -dc /builddir/build/SOURCES/TestSlide-2.6.4.tar.gz + /usr/bin/tar -xof - + STATUS=0 + '[' 0 -ne 0 ']' + cd TestSlide-2.6.4 + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . + /usr/bin/cat /builddir/build/SOURCES/9a62c484ca9360ea8dfca82b244589c733182449.patch + /usr/bin/patch -p1 -s --fuzz=0 --no-backup-if-mismatch + /usr/bin/cat /builddir/build/SOURCES/f0a82aa1bf93863794e8a9867cb34df14fdf62a4.patch + /usr/bin/patch -p1 -s --fuzz=0 --no-backup-if-mismatch + /usr/bin/cat /builddir/build/SOURCES/fa69263d6eaf07df5090dad4c199d1c6d14abf05.patch + /usr/bin/patch -p1 -s --fuzz=0 --no-backup-if-mismatch + rm -rf TestSlide.egg-info + RPM_EC=0 ++ jobs -p + exit 0 Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.vtceJc + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ' + /usr/bin/python3 setup.py build '--executable=/usr/bin/python3 -s' running build running build_py creating build creating build/lib creating build/lib/testslide copying testslide/strict_mock.py -> build/lib/testslide copying testslide/runner.py -> build/lib/testslide copying testslide/patch_attribute.py -> build/lib/testslide copying testslide/patch.py -> build/lib/testslide copying testslide/mock_constructor.py -> build/lib/testslide copying testslide/mock_callable.py -> build/lib/testslide copying testslide/matchers.py -> build/lib/testslide copying testslide/lib.py -> build/lib/testslide copying testslide/import_profiler.py -> build/lib/testslide copying testslide/dsl.py -> build/lib/testslide copying testslide/cli.py -> build/lib/testslide copying testslide/__init__.py -> build/lib/testslide copying testslide/py.typed -> build/lib/testslide + make docs V=1 DOCS make -C docs/ html make[1]: Entering directory '/builddir/build/BUILD/TestSlide-2.6.4/docs' Running Sphinx v3.4.3 making output directory... done building [mo]: targets for 0 po files that are out of date building [html]: targets for 19 source files that are out of date updating environment: [new config] 19 added, 0 changed, 0 removed reading sources... [ 5%] code_snippets/index reading sources... [ 10%] index reading sources... [ 15%] patching/argument_matchers/index reading sources... [ 21%] patching/cheat_sheet/index reading sources... [ 26%] patching/index reading sources... [ 31%] patching/mock_async_callable/index reading sources... [ 36%] patching/mock_callable/index reading sources... [ 42%] patching/mock_constructor/index reading sources... [ 47%] patching/patch_attribute/index reading sources... [ 52%] strict_mock/index reading sources... [ 57%] test_runner/index reading sources... [ 63%] testslide_dsl/async_support/index reading sources... [ 68%] testslide_dsl/context_attributes_and_functions/index reading sources... [ 73%] testslide_dsl/context_hooks/index reading sources... [ 78%] testslide_dsl/contexts_and_examples/index reading sources... [ 84%] testslide_dsl/index reading sources... [ 89%] testslide_dsl/shared_contexts/index reading sources... [ 94%] testslide_dsl/skip_and_focus/index reading sources... [100%] testslide_dsl/unittest_testcase_integration/index looking for now-outdated files... none found pickling environment... done checking consistency... done preparing documents... done writing output... [ 5%] code_snippets/index writing output... [ 10%] index writing output... [ 15%] patching/argument_matchers/index writing output... [ 21%] patching/cheat_sheet/index writing output... [ 26%] patching/index writing output... [ 31%] patching/mock_async_callable/index writing output... [ 36%] patching/mock_callable/index writing output... [ 42%] patching/mock_constructor/index writing output... [ 47%] patching/patch_attribute/index writing output... [ 52%] strict_mock/index writing output... [ 57%] test_runner/index writing output... [ 63%] testslide_dsl/async_support/index writing output... [ 68%] testslide_dsl/context_attributes_and_functions/index writing output... [ 73%] testslide_dsl/context_hooks/index writing output... [ 78%] testslide_dsl/contexts_and_examples/index writing output... [ 84%] testslide_dsl/index writing output... [ 89%] testslide_dsl/shared_contexts/index writing output... [ 94%] testslide_dsl/skip_and_focus/index writing output... [100%] testslide_dsl/unittest_testcase_integration/index generating indices... genindex done writing additional pages... search done copying images... [ 50%] test_fail.png copying images... [100%] test_pass.png copying static files... done copying extra files... done dumping search index in English (code: en)... done dumping object inventory... done build succeeded. The HTML pages are in _build/html. make[1]: Leaving directory '/builddir/build/BUILD/TestSlide-2.6.4/docs' + RPM_EC=0 ++ jobs -p + exit 0 Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.9DcsON + umask 022 + cd /builddir/build/BUILD + '[' /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 '!=' / ']' + rm -rf /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 ++ dirname /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 + mkdir -p /builddir/build/BUILDROOT + mkdir /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 + cd TestSlide-2.6.4 + CFLAGS='-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' + LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ' + /usr/bin/python3 setup.py install -O1 --skip-build --root /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 running install running install_lib creating /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr creating /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib creating /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9 creating /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages creating /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/py.typed -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/__init__.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/cli.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/dsl.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/import_profiler.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/lib.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/matchers.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/mock_callable.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/mock_constructor.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/patch.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/patch_attribute.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/runner.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide copying build/lib/testslide/strict_mock.py -> /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/__init__.py to __init__.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/cli.py to cli.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/dsl.py to dsl.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/import_profiler.py to import_profiler.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/lib.py to lib.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/matchers.py to matchers.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/mock_callable.py to mock_callable.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/mock_constructor.py to mock_constructor.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/patch.py to patch.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/patch_attribute.py to patch_attribute.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/runner.py to runner.cpython-39.pyc byte-compiling /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/testslide/strict_mock.py to strict_mock.cpython-39.pyc writing byte-compilation script '/tmp/tmp4s6jvwy8.py' /usr/bin/python3 /tmp/tmp4s6jvwy8.py removing /tmp/tmp4s6jvwy8.py running install_egg_info running egg_info creating TestSlide.egg-info writing TestSlide.egg-info/PKG-INFO writing dependency_links to TestSlide.egg-info/dependency_links.txt writing entry points to TestSlide.egg-info/entry_points.txt writing requirements to TestSlide.egg-info/requires.txt writing top-level names to TestSlide.egg-info/top_level.txt writing manifest file 'TestSlide.egg-info/SOURCES.txt' reading manifest file 'TestSlide.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' writing manifest file 'TestSlide.egg-info/SOURCES.txt' Copying TestSlide.egg-info to /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages/TestSlide-2.6.4-py3.9.egg-info running install_scripts Installing testslide script to /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/bin + rm -rfv /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/bin/__pycache__ + /usr/lib/rpm/find-debuginfo.sh -j2 --strict-build-id -m -i --build-id-seed 2.6.4-2.fc34 --unique-debug-suffix -2.6.4-2.fc34.x86_64 --unique-debug-src-base python-TestSlide-2.6.4-2.fc34.x86_64 --run-dwz --dwz-low-mem-die-limit 10000000 --dwz-max-die-limit 110000000 -S debugsourcefiles.list /builddir/build/BUILD/TestSlide-2.6.4 find: 'debug': No such file or directory + /usr/lib/rpm/check-buildroot + /usr/lib/rpm/redhat/brp-ldconfig + /usr/lib/rpm/brp-compress + /usr/lib/rpm/redhat/brp-strip-lto /usr/bin/strip + /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip + /usr/lib/rpm/redhat/brp-python-bytecompile '' 1 0 Bytecompiling .py files below /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9 using /usr/bin/python3.9 + /usr/lib/rpm/brp-python-hardlink + /usr/lib/rpm/redhat/brp-mangle-shebangs Executing(%check): /bin/sh -e /var/tmp/rpm-tmp.skM2e0 + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + export PYTHONPATH=/builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages + PYTHONPATH=/builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/lib/python3.9/site-packages + make tests V=1 COVERAGE ERASE coverage erase UNITTEST tests/cli_unittest.py coverage run \ -m unittest \ --verbose \ --failfast \ tests/cli_unittest.py test_colored_output_to_terminal (tests.cli_unittest.TestCliDocumentFormatter) Execute all examples in the order defined with colored output. ... ok test_colored_output_with_force_color (tests.cli_unittest.TestCliDocumentFormatter) Execute all examples in the order defined with colored output. ... ok test_default_trim_path_prefix (tests.cli_unittest.TestCliDocumentFormatter) Default value for --trim-path-prefix trims path shared with ... ok test_dsl_debug (tests.cli_unittest.TestCliDocumentFormatter) ... ok test_empty_trim_path_prefix (tests.cli_unittest.TestCliDocumentFormatter) Trims nothing if '' passed to --trim-path-prefix. ... ok test_exclude_regexp (tests.cli_unittest.TestCliDocumentFormatter) Skip examples matching regex filter. ... ok test_fail_fast (tests.cli_unittest.TestCliDocumentFormatter) Stop execution when first example fails. ... ok test_fail_if_focus (tests.cli_unittest.TestCliDocumentFormatter) Fail because there are focused tests and --fail-if-focused ... ok test_focus (tests.cli_unittest.TestCliDocumentFormatter) Execute only focused examples. ... ok test_nonempty_trim_path_prefix (tests.cli_unittest.TestCliDocumentFormatter) Trims prefix passed to --trim-path-prefix. ... ok test_not_show_testslide_stack_trace (tests.cli_unittest.TestCliDocumentFormatter) ... ok test_plain_output_without_terminal (tests.cli_unittest.TestCliDocumentFormatter) Execute all examples in the order defined without color. ... ok test_prints_exceptions_with_cause (tests.cli_unittest.TestCliDocumentFormatter) ... ok test_regexp_filter (tests.cli_unittest.TestCliDocumentFormatter) Execute only examples matching regex filter. ... ok test_shuffle (tests.cli_unittest.TestCliDocumentFormatter) Shuffle execution order. ... ok test_text_filter (tests.cli_unittest.TestCliDocumentFormatter) Execute only examples matching partial text filter. ... ok test_list (tests.cli_unittest.TestCliList) With --list, print test names one per line. ... ok test_colored_output_to_terminal (tests.cli_unittest.TestCliLongFormatter) Execute all examples in the order defined with colored output. ... ok test_colored_output_with_force_color (tests.cli_unittest.TestCliLongFormatter) Execute all examples in the order defined with colored output. ... ok test_default_trim_path_prefix (tests.cli_unittest.TestCliLongFormatter) Default value for --trim-path-prefix trims path shared with ... ok test_dsl_debug (tests.cli_unittest.TestCliLongFormatter) ... ok test_empty_trim_path_prefix (tests.cli_unittest.TestCliLongFormatter) Trims nothing if '' passed to --trim-path-prefix. ... ok test_nonempty_trim_path_prefix (tests.cli_unittest.TestCliLongFormatter) Trims prefix passed to --trim-path-prefix. ... ok test_not_show_testslide_stack_trace (tests.cli_unittest.TestCliLongFormatter) ... ok test_plain_output_without_terminal (tests.cli_unittest.TestCliLongFormatter) Execute all examples in the order defined without color. ... ok test_prints_exceptions_with_cause (tests.cli_unittest.TestCliLongFormatter) ... ok test_default_trim_path_prefix (tests.cli_unittest.TestCliProgressFormatter) Default value for --trim-path-prefix trims path shared with ... ok test_dsl_debug (tests.cli_unittest.TestCliProgressFormatter) ... ok test_empty_trim_path_prefix (tests.cli_unittest.TestCliProgressFormatter) Trims nothing if '' passed to --trim-path-prefix. ... ok test_nonempty_trim_path_prefix (tests.cli_unittest.TestCliProgressFormatter) Trims prefix passed to --trim-path-prefix. ... ok test_not_show_testslide_stack_trace (tests.cli_unittest.TestCliProgressFormatter) ... ok test_ouputs_colored_dots_with_terminal (tests.cli_unittest.TestCliProgressFormatter) ... ok test_ouputs_dots (tests.cli_unittest.TestCliProgressFormatter) ... ok test_prints_exceptions_with_cause (tests.cli_unittest.TestCliProgressFormatter) ... ok test_with_quiet (tests.cli_unittest.TestCliQuiet) With --quiet, swallow both stderr and stdout unless the test fails. ... ok test_without_quiet (tests.cli_unittest.TestCliQuiet) Without --quiet, allow test stdout and stderr to go on. ... ok ---------------------------------------------------------------------- Ran 36 tests in 9.134s OK UNITTEST tests/dsl_unittest.py coverage run \ -m unittest \ --verbose \ --failfast \ tests/dsl_unittest.py test_async_memoize_before (tests.dsl_unittest.SmokeTestAsync) ... ok test_can_not_async_memoize (tests.dsl_unittest.SmokeTestAsync) ... ok test_can_not_mix_async_hooks_with_sync_example (tests.dsl_unittest.SmokeTestAsync) ... ok test_can_not_mix_sync_hooks_with_async_example (tests.dsl_unittest.SmokeTestAsync) ... ok test_can_run_async_example_and_hooks (tests.dsl_unittest.SmokeTestAsync) ... ok test_fail_if_coroutine_not_awaited (tests.dsl_unittest.SmokeTestAsync) ... ok test_fail_if_slow_task (tests.dsl_unittest.SmokeTestAsync) ... ok test_resetting_attribute_raises_ValueError (tests.dsl_unittest.SmokeTestAsync) ... ok test_should_not_run (tests.dsl_unittest.SomeTestCase) ... ok test_should_not_run (tests.dsl_unittest.SomeTestCase2) ... ok test_catches_leaked_tasks (tests.dsl_unittest.TestAsyncRun) ... ok test_after_hook (tests.dsl_unittest.TestDSLAfterHook) After hooks can be declared with @context.after decorator. They will ... ok test_after_hook_as_lambda (tests.dsl_unittest.TestDSLAfterHook) ... ok test_after_hook_fail (tests.dsl_unittest.TestDSLAfterHook) When one of the after hooks fails, all other after hooks are still ... ok test_after_hook_from_example (tests.dsl_unittest.TestDSLAfterHook) After hooks can be declared with @self.after decorator from an example. ... ok test_assertions_run_after_after_hooks (tests.dsl_unittest.TestDSLAfterHook) Assertions must be the last thing executed, allowing any registered ... ok test_cant_call_after_function_directly (tests.dsl_unittest.TestDSLAfterHook) It is not allowed to call an after hook directly. ... ok test_cant_define_after_on_top (tests.dsl_unittest.TestDSLAfterHook) After hooks can only be called within a declared context. ... ok test_around_cant_be_called_directly (tests.dsl_unittest.TestDSLAroundHook) It is not allowed to call around hooks directly. ... ok test_around_cant_be_set_on_top (tests.dsl_unittest.TestDSLAroundHook) Around hooks must be declared within a declared context. ... ok test_around_failure_aborts_execution (tests.dsl_unittest.TestDSLAroundHook) If the code before example() in an around hook fails, the ... ok test_around_hook (tests.dsl_unittest.TestDSLAroundHook) Around hooks can be declared with @context.around decorator. The ... ok test_can_set_arbitrary_attributes (tests.dsl_unittest.TestDSLAroundHook) Within before, after and around hooks, it is allowed to defined ... ok test_fails_if_example_not_called (tests.dsl_unittest.TestDSLAroundHook) ... ok test_before_hook (tests.dsl_unittest.TestDSLBeforeHook) Arbitrary before hooks can be declared with @context.before decorator. ... ok test_before_hook_as_lambda (tests.dsl_unittest.TestDSLBeforeHook) ... ok test_before_hook_fail (tests.dsl_unittest.TestDSLBeforeHook) When one before hook fails, stop example execution. ... ok test_cant_call_before_function_directly (tests.dsl_unittest.TestDSLBeforeHook) It is not allowed to call a before hook directly. ... ok test_cant_define_before_on_top (tests.dsl_unittest.TestDSLBeforeHook) Before hooks are only allowed within a context. ... ok test_can_be_named_from_decorator (tests.dsl_unittest.TestDSLContext) Contexts can be named with an argument for @context decorator. ... ok test_can_be_named_from_function (tests.dsl_unittest.TestDSLContext) Contexts can have its name extracted from the function decorated by ... ok test_can_create_nested_contexts_with_same_name (tests.dsl_unittest.TestDSLContext) It is allowed to have a nested context wih the same name as its parent. ... ok test_can_nest_contexts (tests.dsl_unittest.TestDSLContext) Contexts can be nested arbitrarily below a top context. ... ok test_cant_call_context_function (tests.dsl_unittest.TestDSLContext) Context functions are not meant to be called directly. ... ok test_cant_create_nested_contexts_with_same_name (tests.dsl_unittest.TestDSLContext) User should get a clear error when trying to create two contexts with ... ok test_cant_create_top_contexts_with_same_name (tests.dsl_unittest.TestDSLContext) User should get a clear error when trying to create two contexts with ... ok test_focus_contexts (tests.dsl_unittest.TestDSLContext) Contexts can be marked as focused by using the prefix "f" to either ... ok test_multiple_top_contexts (tests.dsl_unittest.TestDSLContext) We can have multiple top contexts declared. ... ok test_skip_contexts (tests.dsl_unittest.TestDSLContext) Contexts can be marked as skipped by using the prefix "x" to either ... ok test_cant_create_helper_function_on_top (tests.dsl_unittest.TestDSLHelperFunction) It is not allowed to create a helper function outside of a context. ... ok test_cant_create_two_helper_functions_with_same_name (tests.dsl_unittest.TestDSLHelperFunction) User gets a clear error mesasge when trying to create two helper ... ok test_helper_function_cant_be_called_directly (tests.dsl_unittest.TestDSLHelperFunction) Helper functions are not meant to be called directly. ... ok test_helper_functions (tests.dsl_unittest.TestDSLHelperFunction) Arbitrary functions can be declared to example execution scope with ... ok test_cant_call_memoizable_functions_directly (tests.dsl_unittest.TestDSLMemoizedAttribute) It is not allowed to call memoized attributes directly. ... ok test_cant_create_two_memoizable_with_same_name (tests.dsl_unittest.TestDSLMemoizedAttribute) User should get a clear error when trying to declare two memoized ... ok test_memoize_attribute (tests.dsl_unittest.TestDSLMemoizedAttribute) Arbitrary attributes can be defined to example execution scope, by ... ok test_memoize_attribute_as_lambda (tests.dsl_unittest.TestDSLMemoizedAttribute) Memoize attributes can be declared by passing the attribute name and ... ok test_memoize_attribute_with_kwargs (tests.dsl_unittest.TestDSLMemoizedAttribute) Memoize attributes can be declared by passing attributes as kwargs. ... ok test_cant_call_memoize_before_functions_directly (tests.dsl_unittest.TestDSLMemoizedBeforeAttribute) Similar to @context.memoize. ... ok test_cant_create_two_memoize_before_with_same_name (tests.dsl_unittest.TestDSLMemoizedBeforeAttribute) Similar to @context.memoize. ... ok test_cant_do_composition (tests.dsl_unittest.TestDSLMemoizedBeforeAttribute) Similar to @context.memoize. ... ok test_memoize_before_attribute (tests.dsl_unittest.TestDSLMemoizedBeforeAttribute) Similar to @context.memoize, but materializes the value at a before ... ok test_memoize_before_attribute_as_lambda (tests.dsl_unittest.TestDSLMemoizedBeforeAttribute) Similar to @context.memoize with a lambda, but materializes the value at ... ok test_cant_merge_test_case_on_top (tests.dsl_unittest.TestDSLMergeTestCase) ... ok test_merge_test_case (tests.dsl_unittest.TestDSLMergeTestCase) merge_test_case allows to integrate existing unittest.TestCase classes ... ok test_report_merged_test_case_failures (tests.dsl_unittest.TestDSLMergeTestCase) Properly report failures with TestCase merging. ... ok test_cant_create_two_shared_contexts_with_same_name (tests.dsl_unittest.TestDSLSharedContext) User should get a clear error when trying to create two shared contexts ... ok test_cant_merge_shared_context_on_top (tests.dsl_unittest.TestDSLSharedContext) It makes no sense to merge a shared context on top level. ... ok test_cant_nest_shared_context_on_top (tests.dsl_unittest.TestDSLSharedContext) It is not allowed to nest a shared context directly on top level. ... ok test_inherit_shared_context (tests.dsl_unittest.TestDSLSharedContext) Nested contexts inherits shared contexts declared in its parents. ... ok test_merge_invalid_shared_context (tests.dsl_unittest.TestDSLSharedContext) User gets a clear error message when trying to merge an invalid ... ok test_merge_shared_context (tests.dsl_unittest.TestDSLSharedContext) Shared contexts can be merged inside a context with ... ok test_nest_invalid_shared_context (tests.dsl_unittest.TestDSLSharedContext) User should get a clear error message when trying to nest an invalid ... ok test_nest_shared_context (tests.dsl_unittest.TestDSLSharedContext) Shared conetxts can be nested below other contexts with ... ok test_shared_context_named_from_decorator (tests.dsl_unittest.TestDSLSharedContext) Shared contexts can be declared with the @context.shared_context ... ok test_shared_context_named_from_function (tests.dsl_unittest.TestDSLSharedContext) Shared contexts can be declared with the @context.shared_context ... ok test_can_be_named_from_decorator (tests.dsl_unittest.TestExample) Examples can be declared with @context.example(name) decorator. ... ok test_can_be_named_from_function (tests.dsl_unittest.TestExample) Examples can be declared with @context.example decorator, and its ... ok test_can_call_unittest_assert_methods (tests.dsl_unittest.TestExample) Python's unittest.TestCase assert* methods are available to use. ... ok test_can_define_sub_examples (tests.dsl_unittest.TestExample) Sub examples can be defined, and failures are aggregated at the end. ... ok test_cant_call_example_function (tests.dsl_unittest.TestExample) It is not allowed to call example function directly. ... ok test_cant_create_example_outside_context (tests.dsl_unittest.TestExample) Examples must be declared within a context. ... ok test_cant_create_two_with_same_name (tests.dsl_unittest.TestExample) User should get a clear error message if two examples with the same ... ok test_focus_with_fexample (tests.dsl_unittest.TestExample) An example can be focused as with @context.fexample. ... ok test_inherits_focus_from_fcontext (tests.dsl_unittest.TestExample) Examples inherit focus setting from parent context. ... ok test_inherits_skip_from_xcontext (tests.dsl_unittest.TestExample) Examples inherit skip setting from parent context. ... ok test_skip_with_xexample (tests.dsl_unittest.TestExample) An example can be declared as skip with @context.xexample. ... ok test_get_not_done_tasks_all_tasks_done (tests.dsl_unittest.TestGetNotDoneTasks) ... ok test_get_not_done_tasks_no_tasks_done (tests.dsl_unittest.TestGetNotDoneTasks) ... ok test_get_not_done_tasks_skips_done_tasks (tests.dsl_unittest.TestGetNotDoneTasks) ... ok test_leaked_tasks_fails_test_run (tests.dsl_unittest.TestMockAsyncCallableIntegration) ... ok test_mock_async_callable_integration (tests.dsl_unittest.TestMockAsyncCallableIntegration) ... ok test_mock_callable_integration (tests.dsl_unittest.TestMockCallableIntegration) ... ok test_mock_constructor_integration (tests.dsl_unittest.TestMockConstructorIntegration) ... ok test_patch_attribute_integration (tests.dsl_unittest.TestPatchAttributeIntegration) ... ok ---------------------------------------------------------------------- Ran 85 tests in 0.248s OK UNITTEST tests/matchers_unittest.py coverage run \ -m unittest \ --verbose \ --failfast \ tests/matchers_unittest.py test_FloatBetween (tests.matchers_unittest.FloatMatcherTest) ... ok test_FloatGreaterOrEquals (tests.matchers_unittest.FloatMatcherTest) ... ok test_FloatGreaterThan (tests.matchers_unittest.FloatMatcherTest) ... ok test_FloatLessOrEquals (tests.matchers_unittest.FloatMatcherTest) ... ok test_FloatLessThan (tests.matchers_unittest.FloatMatcherTest) ... ok test_NotThisFloat (tests.matchers_unittest.FloatMatcherTest) ... ok testAny (tests.matchers_unittest.GenericTestCase) ... ok testAnyFalsey (tests.matchers_unittest.GenericTestCase) ... ok testAnyInstanceOf (tests.matchers_unittest.GenericTestCase) ... ok testAnyTruthy (tests.matchers_unittest.GenericTestCase) ... ok testAnyWithCall (tests.matchers_unittest.GenericTestCase) ... ok testAnyInt (tests.matchers_unittest.IntMatcherTest) ... ok test_IntBetween (tests.matchers_unittest.IntMatcherTest) ... ok test_IntGreaterOrEquals (tests.matchers_unittest.IntMatcherTest) ... ok test_IntGreaterThan (tests.matchers_unittest.IntMatcherTest) ... ok test_IntLessOrEquals (tests.matchers_unittest.IntMatcherTest) ... ok test_IntLessThan (tests.matchers_unittest.IntMatcherTest) ... ok test_NotThisInt (tests.matchers_unittest.IntMatcherTest) ... ok testAnyStr (tests.matchers_unittest.StringTest) ... ok testRegexMatches (tests.matchers_unittest.StringTest) ... ok testStrContaining (tests.matchers_unittest.StringTest) ... ok testStrEndingWith (tests.matchers_unittest.StringTest) ... ok testStrStartingWith (tests.matchers_unittest.StringTest) ... ok testBitwiseAnd (tests.matchers_unittest.TestChaining) ... ok testBitwiseInverse (tests.matchers_unittest.TestChaining) ... ok testBitwiseOr (tests.matchers_unittest.TestChaining) ... ok testBitwiseXor (tests.matchers_unittest.TestChaining) ... ok testCannotChainMoreThanTwo (tests.matchers_unittest.TestChaining) ... ok testAnyDict (tests.matchers_unittest.TestDicts) ... ok testDictContainingKeys (tests.matchers_unittest.TestDicts) ... ok testDictSupersetOf (tests.matchers_unittest.TestDicts) ... ok testEmptyDict (tests.matchers_unittest.TestDicts) ... ok testNotEmptyDict (tests.matchers_unittest.TestDicts) ... ok testAnyList (tests.matchers_unittest.TestLists) ... ok testListContainingAll (tests.matchers_unittest.TestLists) ... ok testListContainingElement (tests.matchers_unittest.TestLists) ... ok test_patch_callable (tests.matchers_unittest.TestUsageWithPatchCallable) ... ok ---------------------------------------------------------------------- Ran 37 tests in 0.013s OK UNITTEST tests/testcase_unittest.py coverage run \ -m unittest \ --verbose \ --failfast \ tests/testcase_unittest.py test_has_mock_async_callable (tests.testcase_unittest.TestSlideTestCaseIntegration) ... ok test_has_mock_callable (tests.testcase_unittest.TestSlideTestCaseIntegration) ... ok test_has_mock_constructor (tests.testcase_unittest.TestSlideTestCaseIntegration) ... ok test_has_patch_attribute (tests.testcase_unittest.TestSlideTestCaseIntegration) ... ok test_inherits_from_unittest (tests.testcase_unittest.TestSlideTestCaseIntegration) ... ok ---------------------------------------------------------------------- Ran 5 tests in 0.021s OK TESTSLIDE tests/lib_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/lib_testslide.py _validate_callable_arg_types passes for canonical call with valid types: PASS fails for canonical with invalid types: PASS passes for kwargs as args call with valid types: PASS fails for kwargs as args with invalid types: PASS passes for args as kwargs call with valid types: PASS fails for args as kwargs with invalid types: PASS gives correct error message for invalid types: PASS works with object.__new__: PASS instance method passes for args as starargs call: PASS testslide.StrictMock passes with valid template: PASS passes without template: PASS fails with invalid template: PASS unittest.mock.Mock passes with valid spec: PASS passes without spec: PASS fails with invalid spec: PASS TypeVar ingores TypeVar: PASS ignores nested TypeVar: PASS recursion and mocks typing.Union passes with StritMock without template: PASS it works with unittest.mock.Mock without spec: PASS passes with StritMock with valid template: PASS passes with unittest.mock.Mock with valid spec: PASS fails with StritMock with invalid template: PASS fails with unittest.mock.Mock with invalid spec: PASS typing.Tuple passes with StritMock without template: PASS it works with unittest.mock.Mock without spec: PASS passes with StritMock with valid template: PASS passes with unittest.mock.Mock with valid spec: PASS fails with StritMock with invalid template: PASS fails with unittest.mock.Mock with invalid spec: PASS _validate_return_type passes for correct type: PASS passes for mock without template: PASS passes for mock with correct template: PASS passes if TypeVar in signature: PASS fails for wrong type: PASS fails for mock with wrong template: PASS passes for valid forward reference: PASS fails for valid forward reference but bad type passed: PASS Finished 37 example(s) in 1.0s Successful: 37 TESTSLIDE tests/mock_async_callable_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/mock_async_callable_testslide.py mock_async_callable() when target is a module and callable is a function can not mock: PASS can mock with flag: PASS and callable is an async function default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS when target is a class and callable is a sync instance method can not mock: PASS and callable is a sync class method can not mock: PASS can mock with flag: PASS and callable is a sync static method can not mock: PASS can mock with flag: PASS and callable is a sync magic method can not mock: PASS and callable is an async instance method it is not allowed: PASS and callable is an async class method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS and callable is an async static method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS and callable is an async magic method it is not allowed: PASS an instance and callable is a sync instance method can not mock: PASS can mock with flag: PASS and callable is a sync class method can not mock: PASS can mock with flag: PASS and callable is a sync static method can not mock: PASS can mock with flag: PASS and callable is a sync magic method can not mock: PASS can mock with flag: PASS and callable is an async instance method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS and callable is an async class method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS and callable is an async static method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .to_return_values(value_list) it returns values: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .with_implementation(func) it calls mocked function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS return value type passes with valid type: PASS with invalid return type raises TypeCheckError: PASS with sync function it raises NotACoroutine: PASS and callable is an async magic method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS .to_return_values(value_list) it returns values: PASS .with_implementation(func) it calls mocked function: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it calls function: PASS with sync function it raises NotACoroutine: PASS when target is a StrictMock and callable is a sync instance method can not mock: PASS can mock with flag: PASS and callable is a sync class method can not mock: PASS can mock with flag: PASS and callable is a sync static method can not mock: PASS can mock with flag: PASS and callable is a sync magic method can not mock: PASS can mock with flag: PASS and callable is an async instance method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS .to_return_values(value_list) it returns values: PASS .with_implementation(func) it calls mocked function: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it raises ValueError: PASS and callable is an async class method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS .to_return_values(value_list) it returns values: PASS .with_implementation(func) it calls mocked function: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it raises ValueError: PASS and callable is a async static method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS .to_return_values(value_list) it returns values: PASS .with_implementation(func) it calls mocked function: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it raises ValueError: PASS and callable is an async magic method default behavior: PASS .for_call(): PASS .to_raise(exception): PASS .to_call_original(): PASS .and_assert_*: PASS mock async callable can not assert if already received call: PASS .to_return_value(value) it returns value: PASS .to_return_values(value_list) it returns values: PASS .with_implementation(func) it calls mocked function: PASS with sync function raises NotACoroutine with non async function: PASS .with_wrapper(func) it raises ValueError: PASS Finished 202 example(s) in 1.6s Successful: 202 TESTSLIDE tests/mock_callable_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/mock_callable_testslide.py mock_callable() patching private functions raises valueerror: PASS patching private functions with allow private: PASS stacked same for call it works at declared order: PASS call order assertion it passes with ordered calls: PASS it fails with unordered calls: PASS it fails with partial calls: PASS other mocks do not interfere: PASS stacked same for call works: PASS when target is a module works with alternative module names: PASS and callable is a function default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS /usr/lib64/python3.9/traceback.py:220: RuntimeWarning: coroutine 'coro_fun' was never awaited tb.tb_frame.clear() RuntimeWarning: Enable tracemalloc to get the object allocation traceback return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS /usr/lib64/python3.9/traceback.py:220: RuntimeWarning: coroutine 'mock_callable_tests..mock_configuration_examples..with_wrapper_wrappr_func..with_wrapper_raises_with_coroutine.._wrapper_coro_func' was never awaited tb.tb_frame.clear() RuntimeWarning: Enable tracemalloc to get the object allocation traceback with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is an async function can not mock: PASS when target is a class and callable is an async instance method can not mock: PASS and callable is an async class method can not mock: PASS and callable is an async static method can not mock: PASS and callable is an async magic method can not mock: PASS and callable is an instance method it is not allowed: PASS and callable is a class method default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a static method default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a magic method it is not allowed: PASS an instance and callable is an async instance method can not mock: PASS and callable is an async class method can not mock: PASS and callable is an async static method can not mock: PASS and callable is an async magic method can not mock: PASS and callable is an instance method other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a class method other instances are not mocked: PASS class is not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a static method other instances are not mocked: PASS class is not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS return value passes with valid type: PASS with invalid return type raises TypeCheckError: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS type validation arguments raises TypeCheckError for invalid types: PASS with type_validation=False passes with invalid argument type: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP with matching signature it accepts known arguments: PASS it rejects unknown arguments: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with type_validation=False it doest not type validate: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a magic method with magic method defined on class other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS with magic method defined on parent class other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it calls wrapper function: PASS with wrapper raises with coroutine: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_call_original() it calls original implementation: PASS mock call signature passes with valid signature: PASS raises TypeError for mismatching signature: PASS .for_call(*args, **kwargs) with mismatching signature it fails to mock: SKIP assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when target is a StrictMock and callable is an async instance method can not mock: PASS and callable is an async class method can not mock: PASS and callable is an async static method can not mock: PASS and callable is an async magic method can not mock: PASS and callable is an instance method that is statically defined at the class other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it fails to mock: PASS .to_call_original() it fails to mock: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS that is dynamically defined by the instance other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it fails to mock: PASS .to_call_original() it fails to mock: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a class method other instances are not mocked: PASS class is not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it fails to mock: PASS .to_call_original() it fails to mock: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a static method other instances are not mocked: PASS class is not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_yield_values(values_list) yield values from list in order: PASS yield values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is empty it raises StopIteration: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it fails to mock: PASS .to_call_original() it fails to mock: PASS composition newest mock has precedence over older mocks: PASS multiple assertions that passes: PASS that fails: PASS and callable is a magic method other instances are not mocked: PASS default behavior mock call fails with undefined behavior: PASS can not define call assertions: PASS mock callable can not assert if already received call: PASS .and_assert_not_called() passes when not called: PASS fails when called: PASS .to_return(value) mock call returns given value: PASS return value raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .to_return_values(values_list) return values from list in order: PASS return values raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when list is exhausted it raises: PASS .to_raise(exception) when given an exception class it raises an instance of the class: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS when given an exception instance it raises the exception instance: PASS integration assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_implementation(func) it calls new implementation: PASS with implementation raises with coroutine: PASS assertions .and_assert_called_exactly(times) with valid input fails when not called: PASS called less times: PASS called more times: PASS passes when called exactly times: PASS .and_assert_called_at_least(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called less times: PASS passes when called exactly times: PASS called more times: PASS .and_assert_called_at_most(times) with invalid input fails to mock when times < 1: PASS with valid input fails when not called: PASS called more times: PASS passes when called less times: PASS called exactly times: PASS .and_assert_called() fails when not called: PASS passes when called once: PASS called several times: PASS .and_assert_not_called() can use with previously existing behavior: PASS .with_wrapper(wrapper_func) it fails to mock: PASS .to_call_original() it fails to mock: PASS Finished 2384 example(s) in 6.9s Successful: 2322 Skipped: 62 TESTSLIDE tests/mock_constructor_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/mock_constructor_testslide.py mock_constructor() private patching raises valueerror: PASS private patching allow private: PASS patching mechanism can not mock constructor with existing instances: PASS works with composition: PASS original class attribute access can not create new instances: PASS can access class attributes: PASS can call class methods: PASS can call static methods: PASS arguments refuses to mock if instances exist: PASS module accepts string: PASS accepts reference: PASS class rejects non string class name: PASS rejects non class targets: PASS class attributes at the class attributes are not affected: PASS static methods are not affected: PASS class methods are not affected: PASS super(Target, cls) works: PASS super() works: PASS mock_callable() integration it uses mock callable interface: PASS registers call count and args correctly: PASS mock constructor can not assert if already received call: PASS behavior .to_call_original() works: PASS .with_implementation() works: PASS .with_wrapper() wrapped instance is instance of original class: PASS constructor is wrapped: PASS factory works: PASS class attributes at the instance attributes are not affected: PASS static methods are not affected: PASS class methods are not affected: PASS super(Target, cls) works: PASS super() works: PASS Target.__init__() super(Target, self): PASS super() works: PASS can be called again: PASS instance methods it works: PASS when it overloads parent method super(Target, self) works: PASS super() works: PASS StrictMock integration with target mock memoized before patching works: PASS mock_callable() works: PASS dynamic attributes work: PASS with target mock memoized patching works: PASS mock_callable() works: PASS dynamic attributes work: PASS type validation it passes with valid types: PASS it fails with invalid types: PASS with type_validation=False it passes with invalid types: PASS Finished 46 example(s) in 1.2s Successful: 46 TESTSLIDE tests/patch_attribute_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/patch_attribute_testslide.py patch_attribute() patch attribute raises valueerror for private: PASS patch attribute passes for private with allow private: PASS when target is a module given as a reference it fails if attribute is callable: PASS it fails if attribute is a class: PASS patching works patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS given as a string it fails if attribute is callable: PASS it fails if attribute is a class: PASS patching works patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS when target is a class it fails if attribute is callable: PASS patching works patching works: PASS double patching works: PASS with class attributes patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS when target is an instance it fails if attribute is callable: PASS patching works patching works: PASS double patching works: PASS with class attributes patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS and attribute is a property it fails if attribute is callable: PASS patching works patching works: PASS double patching works: PASS with class attributes patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS when target is a StrictMock with a template it fails if attribute is callable: PASS patching works patching works: PASS double patching works: PASS with class attributes patching works: PASS double patching works: PASS type validation it fails if new value is of incompatible type: PASS it passes if new value is of incompatible type with type validation false: PASS it passes if new value is of matching type: PASS without a template patching works: PASS double patching works: PASS Finished 50 example(s) in 1.0s Successful: 50 TESTSLIDE tests/strict_mock_testslide.py coverage run \ -m testslide.cli \ --format documentation \ --show-testslide-stack-trace \ --fail-fast \ --fail-if-focused \ tests/strict_mock_testslide.py StrictMock without template can access attributes: PASS raises when an undefined attribute is accessed: PASS allows mocking any attribute: PASS allows deleting a mocked attribute: PASS allows mocking any method: PASS allows mocking context manager methods: PASS attribute type is maintained: PASS with a template by subclassing StrictMock overriding regular methods work: PASS overriding magic methods work: PASS given as an argument sync attributes non callable attributes raises when an undefined attribute is accessed: PASS shows the correct file and linenum when raising when an undefined attribute is accessed: PASS raises when an non existing attribute is accessed: PASS raises when setting non existing attributes: PASS allows existing attributes to be set: PASS allows init set attributes to be set: PASS allows parent init set attributes to be set: PASS can set runtime attrs: PASS can set slots attribute: PASS attribute type is maintained: PASS type validation allows setting valid type: PASS raises with invalid template: PASS allows setting valid type with templated mock: PASS allows setting valid type with generic mock: PASS raises TypeCheckError when setting invalid type: PASS raises TypeCheckError when setting with mock with invalid type template: PASS with type_validation=False allows setting invalid type: PASS allows setting with mock with invalid type template: PASS callable attributes works with mock callable: PASS instance methods failures raises when setting a non callable value: PASS raises when an undefined method is accessed: PASS signature and type validation works with wraps: PASS with type_validation=True fails on invalid signature call: PASS fails on invalid argument type call: PASS fails on invalid return type: PASS with type_validation=False passes on invalid argument type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS success isinstance is true for template: PASS method mocking can access attributes: PASS can mock with function: PASS can mock with lambda: PASS can mock with instancemethod: PASS static methods failures raises when setting a non callable value: PASS raises when an undefined method is accessed: PASS signature and type validation works with wraps: PASS with type_validation=True fails on invalid signature call: PASS fails on invalid argument type call: PASS fails on invalid return type: PASS with type_validation=False passes on invalid argument type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS success isinstance is true for template: PASS method mocking can access attributes: PASS can mock with function: PASS can mock with lambda: PASS can mock with instancemethod: PASS class methods failures raises when setting a non callable value: PASS raises when an undefined method is accessed: PASS signature and type validation works with wraps: PASS with type_validation=True fails on invalid signature call: PASS fails on invalid argument type call: PASS fails on invalid return type: PASS with type_validation=False passes on invalid argument type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS success isinstance is true for template: PASS method mocking can access attributes: PASS can mock with function: PASS can mock with lambda: PASS can mock with instancemethod: PASS magic methods raises when an undefined magic method is accessed: PASS can set magic methods: PASS bool() works: PASS context manager context manager raises UndefinedAttribute: PASS with default_context_manager=True it yields the mock: PASS async attributes instance methods raises when setting a non callable value: PASS signature and type validation with type_validation=True fails on wrong signature call: PASS can mock with async function: PASS can not mock with sync function: PASS fails on wrong type call: PASS fails on invalid return type: PASS with type_validation=False passes on wrong signature call: PASS can mock with async function: PASS can mock with sync function: PASS passes on wrong type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS static methods raises when setting a non callable value: PASS signature and type validation with type_validation=True fails on wrong signature call: PASS can mock with async function: PASS can not mock with sync function: PASS fails on wrong type call: PASS fails on invalid return type: PASS with type_validation=False passes on wrong signature call: PASS can mock with async function: PASS can mock with sync function: PASS passes on wrong type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS class methods raises when setting a non callable value: PASS signature and type validation with type_validation=True fails on wrong signature call: PASS can mock with async function: PASS can not mock with sync function: PASS fails on wrong type call: PASS fails on invalid return type: PASS with type_validation=False passes on wrong signature call: PASS can mock with async function: PASS can mock with sync function: PASS passes on wrong type call: PASS passes on invalid return type: PASS attribute type is maintained: PASS async iterator default raises UndefinedAttribute: PASS can mock async iterator: PASS async context manager default raises UndefinedAttribute: PASS can mock async context manager: PASS default_context_manager=True it yields the mock: PASS making copies copy.copy(): PASS copy.deepcopy(): PASS with TRIM_PATH_PREFIX set __str__ trims prefix: PASS Finished 119 example(s) in 1.3s Successful: 119 MYPY tests testslide util mypy tests testslide util mypy.ini: No [mypy] section in config file Success: no issues found in 26 source files FLAKE8 tests testslide util flake8 --select=F,C90 tests testslide util ISORT tests testslide util isort --check-only --profile black tests testslide util || { echo "Formatting errors found, try running 'make format'."; exit 1; } BLACK tests testslide util black --check tests testslide util || { echo "Formatting errors found, try running 'make format'."; exit 1; } No Python files are present to be formatted. Nothing to do 😴 + RPM_EC=0 ++ jobs -p + exit 0 Processing files: python3-TestSlide-2.6.4-2.fc34.noarch Executing(%doc): /bin/sh -e /var/tmp/rpm-tmp.ra4pfB + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + DOCDIR=/builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide + export LC_ALL=C + LC_ALL=C + export DOCDIR + /usr/bin/mkdir -p /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide + cp -pr README.md /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide + RPM_EC=0 ++ jobs -p + exit 0 Executing(%license): /bin/sh -e /var/tmp/rpm-tmp.EQHpfm + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + LICENSEDIR=/builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/licenses/python3-TestSlide + export LC_ALL=C + LC_ALL=C + export LICENSEDIR + /usr/bin/mkdir -p /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/licenses/python3-TestSlide + cp -pr LICENSE /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/licenses/python3-TestSlide + RPM_EC=0 ++ jobs -p + exit 0 Provides: python-TestSlide = 2.6.4-2.fc34 python3-TestSlide = 2.6.4-2.fc34 python3.9-TestSlide = 2.6.4-2.fc34 python3.9dist(testslide) = 2.6.4 python3dist(testslide) = 2.6.4 Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PartialHardlinkSets) <= 4.0.4-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1 Requires: /usr/bin/python3 python(abi) = 3.9 python3.9dist(psutil) >= 5.6.7 python3.9dist(pygments) >= 2.2 python3.9dist(setuptools) python3.9dist(typeguard) >= 2.10 Processing files: python3-TestSlide-docs-2.6.4-2.fc34.noarch Executing(%doc): /bin/sh -e /var/tmp/rpm-tmp.DCxAz0 + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + DOCDIR=/builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide-docs + export LC_ALL=C + LC_ALL=C + export DOCDIR + /usr/bin/mkdir -p /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide-docs + cp -pr docs/_build/html /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64/usr/share/doc/python3-TestSlide-docs + RPM_EC=0 ++ jobs -p + exit 0 Provides: python3-TestSlide-docs = 2.6.4-2.fc34 Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1 Checking for unpackaged file(s): /usr/lib/rpm/check-files /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 Wrote: /builddir/build/RPMS/python3-TestSlide-2.6.4-2.fc34.noarch.rpm Wrote: /builddir/build/RPMS/python3-TestSlide-docs-2.6.4-2.fc34.noarch.rpm Executing(%clean): /bin/sh -e /var/tmp/rpm-tmp.uTstl9 + umask 022 + cd /builddir/build/BUILD + cd TestSlide-2.6.4 + /usr/bin/rm -rf /builddir/build/BUILDROOT/python-TestSlide-2.6.4-2.fc34.x86_64 + RPM_EC=0 ++ jobs -p + exit 0 Child return code was: 0