Extending svnmock

svnmock is designed to be as modular as possible; we want you to be able to extend the package as effortlessly as possible. To that end, we've put together this guide to some of the more important cogs and gears you'll be interacting with during the process of writing an extension class.

First up, you'll need to pick a base class. At minimum, you must subclass the State class and conform to the protocol it defines. Beyond that, we offer two additional base classes that serve common needs: SingleState provides a base class for States that can only validate a single API call, while the Container class is a starting point for States that can contain other States.

You'll also want to, at minimum, have a look at the FrozenState class, which is used to provide hashability for States. Additionally, those States that want to offer Command-like functionality should look at the Return class, which is used to trace return values from API call to API call.

svnmock