File: the-functions.rst

package info (click to toggle)
python-mockito 1.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 528 kB
  • sloc: python: 4,102; makefile: 206
file content (27 lines) | stat: -rw-r--r-- 883 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
.. module:: mockito


The functions
=============

Stable entrypoints are: :func:`when`, :func:`mock`, :func:`unstub`, :func:`verify`, :func:`spy`. Experimental or new function introduces with v1.0.x are: :func:`when2`, :func:`expect`, :func:`verifyNoUnwantedInteractions`, :func:`verifyStubbedInvocationsAreUsed`, :func:`patch`

.. autofunction:: when
.. autofunction:: when2
.. autofunction:: patch
.. autofunction:: expect
.. autofunction:: mock
.. autofunction:: unstub
.. autofunction:: forget_invocations
.. autofunction:: spy
.. autofunction:: spy2

This looks like a plethora of verification functions, and especially since  you often don't need to `verify` at all.

.. autofunction:: verify
.. autofunction:: verifyNoMoreInteractions
.. autofunction:: verifyZeroInteractions
.. autofunction:: verifyNoUnwantedInteractions
.. autofunction:: verifyStubbedInvocationsAreUsed