Skip to content

Instantly share code, notes, and snippets.

@adiroiban
Created February 12, 2013 10:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adiroiban/4761516 to your computer and use it in GitHub Desktop.
Save adiroiban/4761516 to your computer and use it in GitHub Desktop.
with nested(
patch(
'chevah.server.commons.commands.copyfile',
),
patch(
'chevah.server.commons.commands.generate_ssh_key',
return_value=(0, 'message'),
),
patch.object(
local_filesystem,
'openFileForWriting',
),
) as (
mock_copyfile,
mock_generate_ssh_key,
mock_openFileForWriting,
):
exit_code, message = commands.initialize(options)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment