예제 #1
0
 def test_get_default_latest_profile(self):
     with mock.patch('azure.cli.core.cloud.CLOUD_CONFIG_FILE',
                     tempfile.mkstemp()[1]):
         cli = DummyCli()
         clouds = get_clouds(cli)
         for c in clouds:
             self.assertEqual(c.profile, 'latest')
예제 #2
0
파일: _params.py 프로젝트: tylerd/azure-cli
def get_cloud_name_completion_list(prefix, action, parsed_args, **kwargs):  # pylint: disable=unused-argument
    return [c.name for c in get_clouds()]
예제 #3
0
파일: custom.py 프로젝트: paulmey/azure-cli
def list_clouds():
    return get_clouds()
예제 #4
0
def _helper_get_clouds(_):
    """ Helper method for multiprocessing.Pool.map func that uses throwaway arg """
    get_clouds(DummyCli())
예제 #5
0
def get_cloud_name_completion_list(prefix, action, parsed_args, **kwargs):  # pylint: disable=unused-argument
    return [c.name for c in get_clouds()]
예제 #6
0
def _helper_get_clouds(_):
    """ Helper method for multiprocessing.Pool.map func that uses throwaway arg """
    get_clouds()
예제 #7
0
 def test_get_default_latest_profile(self):
     with mock.patch('azure.cli.core.cloud.CLOUD_CONFIG_FILE', tempfile.mkstemp()[1]):
         clouds = get_clouds()
         for c in clouds:
             self.assertEqual(c.profile, 'latest')
예제 #8
0
def list_clouds():
    return get_clouds()
예제 #9
0
def list_clouds(cmd):
    return get_clouds(cmd.cli_ctx)
예제 #10
0
def list_clouds(cmd):
    return get_clouds(cmd.cli_ctx)