VMware: Add fake.create_vm()

Add a utility function for creating VMs in tests. Based on the
existing FakeVim._create_vm function which implements CreateVM_Task.
FakeVim._create_vm is refactored to call create_vm.

Change-Id: I4949408420704cd7e6dd4fc11226472362422a93
Update hooks from oslo-incubator copy

Collapse identical methods for pre/post into one method. Copy
over documentation as well. We are getting rid of oslo-incubator's
copy of hooks.py in the following change id, so from now on
nova has the only copy of this module

If55b37ccb20d9bc520909490f4f00de4ed430638

Change-Id: Ie43913fc847ee7ce247862f53c14a2daec433224
Merge "VMware: Add fake.create_vm()"
Merge "Update hooks from oslo-incubator copy"