All Classes and Interfaces
Class
Description
Provides most of the syntax of jMock's "domain-specific language" API.
An object that fakes the behaviour of an
InvocationExpectation
.Returns the next of a sequence of elements each time it is invoked.
Translates
ExpectationError
s into
AssertionError
s that several
test frameworks, including JUnit 4 and TestNG, use to report
errors.A class that "blitzes" an object by calling it many times, from multiple
threads.
This class lets you imposterise abstract and concrete classes
without calling the constructors of the mocked class.
A naming scheme in which the implicit name for a mock object is
the mocked type's name with the first character in lower case.
The acceptable range of times an expectation may be invoked.
Deprecated.
Java11 support is weak, Migrate to org.jmock.lib.imposters.ByteBuddyClassImposteriser
A partial implementation of the
Action
interface that makes it convenient
to implement application-specific actions with inline anonymous classes.A
ScheduledExecutorService
that executes commands on the thread that calls
runNextPendingCommand
, runUntilIdle
or
tick
.Performs multiple actions every time it is invoked.
An object that matches, checks and fakes an
Invocation
An error thrown when an expectation is violated during a test.
Translates expectation errors into error type used by a specific
testing framework.
Backward compatibility Methods added with ASM
A Timeout of fixed duration from the time the FixedTimeout object is
instantiated.
An
ExpectationErrorTranslator
that doesn't do any translation.An object that can creates a proxy of the given type to capture
Invocation
s and pass them to an
Invokable
object for mocking or stubbing.A Timeout that never times out.
The static details about a method and the run-time details of its invocation.
Support distinguish between building expectations and asserting against expectations.
An expectation of zero or more matching invocations.
An object that can receive an
Invocation
.An
Imposteriser
that uses the
Proxy
class of the Java Reflection API.Deprecated.
For JUnit 4 use
JUnitRuleMockery
Translates
ExpectationError
s into JUnit's
AssertionFailedError
s.A
Mockery
that reports expectation errors as JUnit 3 test failures.A
Mockery
that reports expectation errors as JUnit 4 test failures.A
JUnit5Mockery
is a JUnit Extension that manages JMock
expectations and allowances, and asserts that expectations have been met
after each test has finished.A
JUnitRuleMockery
is a JUnit Rule that manages JMock expectations
and allowances, and asserts that expectations have been met after each test
has finished.A naming scheme in which the implicit name for a mock object is
the last word of the mocked type's name in lower case.
A Mockery represents the context, or neighbourhood, of the object(s) under test.
Creates names for mock objects that have not explicitly been
given a name.
A
TestCase
that supports testing with mock objects.A sequence of expectations.
A naming scheme in which the implicit name for a mock object is
the mocked type's name prepend with "mock".
Returns a default value for the invoked method's result type.
Returns an
Enumeration
over a collection.Returns an
Iterator
over a collection.Returns a value.
A sequence of expectations; invocations can be constrained to occur in a strict
order defined by a sequence.
An expectation has one
Action
but can have zero or more SideEffects
that are triggered before the Action.A state machine that is used to constrain the order of invocations.
A ThreadingPolicy that makes the Mockery thread-safe and helps tests
synchronise with background threads.
I synchronise my delegate.
Throws an exception.
Can't use the default package across shared and unshared jars
Thrown to report that a
DeterministicScheduler
has been asked to perform
a blocking wait, which is not supported.A
TestCase
that verifies postconditions after the
test has run and before the fixture has been torn down.Returns nothing from a void method.