Fix wrapMethod error handling

sinon.wrapMethod was actually failing with this error when the property
wasn't defined:
"Cannot read property 'restore' of undefined"

It tried to access wrappedMethod.restore despite results of previous
check if the wrappedMethod is a function.

This commit fixes this issue and the corresponding test.
Merge pull request #449 from deltaidea/fix-wrapMethod

Fix wrapMethod error handling