The jMock Cookbook
How to...
- Get Started1
- Create Mock Objects, States & Sequences with Less Boilerplate2
- Define Expectations3
- Return Values from Mocked Methods4
- Throw Exceptions from Mocked Methods5
- Match Parameter Values6
- Precisely Specify Expected Parameter Values7
- Expect Methods More (or Less) than Once8
- Expect a Sequence of Invocations9
- Expect an Invocation Between Two Other Invocations10
- Ignore Irrelevant Mock Objects11
- Override Expectations Defined in the Test Set-Up12
- Match Objects and Methods13
- Write New Matchers14
- Write New Actions15
- Easily Define Actions with Scripts16
- Mock Generic Types23
- Mock Abstract and Concrete Classes24
- Use jMock with Languages Other Than Java25
- Upgrade from jMock 1 to jMock 226
- Use jMock in Maven Builds27
- Understand method dispatch in jMock 228
- Mock Classes in Eclipse Plug-in Tests29
- Mock asynchronous GWT services30
To discuss or suggest entries in this Cookbook please join the jMock Users mailing list31.