Properly ensuring that PutObject is called and stubbed on tests