コード例 #1
0
 def test_deploy_operation_direct(self):
     with self.assertRaises(SystemExit) as e:
         _main(
             inventory=path.join('tests', 'test_deploy', 'inventories',
                                 'inventory.py'),
             operations=['server.shell', 'echo hi'],
             verbosity=0,
             user=None,
             port=None,
             key=None,
             key_password=None,
             password=None,
             sudo=False,
             sudo_user=None,
             use_sudo_password=False,
             su_user=None,
             parallel=None,
             fail_percent=0,
             dry=False,
             limit=None,
             no_wait=False,
             serial=False,
             winrm_username=None,
             winrm_password=None,
             winrm_port=None,
             shell_executable=None,
             quiet=False,
             debug=False,
             debug_data=False,
             debug_facts=False,
             debug_operations=False,
         )
         assert e.args == (0, )
コード例 #2
0
ファイル: test_cli.py プロジェクト: morrison12/pyinfra
 def test_deploy_operation_direct(self):
     with self.assertRaises(SystemExit) as e:
         _main(
             inventory=path.join("tests", "test_deploy", "inventories",
                                 "inventory.py"),
             operations=["server.shell", "echo hi"],
             chdir=None,
             group_data=None,
             verbosity=0,
             ssh_user=None,
             ssh_port=None,
             ssh_key=None,
             ssh_key_password=None,
             ssh_password=None,
             sudo=False,
             sudo_user=None,
             use_sudo_password=False,
             su_user=None,
             parallel=None,
             fail_percent=0,
             dry=False,
             limit=None,
             no_wait=False,
             serial=False,
             winrm_username=None,
             winrm_password=None,
             winrm_port=None,
             winrm_transport=None,
             shell_executable=None,
             quiet=False,
             data=tuple(),
             debug=False,
             debug_facts=False,
             debug_operations=False,
             config_filename="config.py",
         )
         assert e.args == (0, )