By default ``patch`` will fail to replace attributes that don't exist. If you
pass in 'create=True' and the attribute doesn't exist, patch will create the
attribute for you when the patched function is called, and delete it again
afterwards. This is useful for writing tests against attributes that your
production code creates at runtime. It is off by by default because it can be
dangerous. With it switched on you can write passing tests against APIs that
don't actually exist!
Patch can be also used as a TestCase class decorator. It works by decorating each test method in the class. This reduces the boilerplate code when your test methods share a common patchings set. ::