Пример #1
0
    def Run(self, args):
        """This is what gets called when the user runs this command.

    Args:
      args: an argparse namespace. All the arguments that were provided to this
        command invocation.

    Returns:
      Some value that we want to have printed later.
    """
        instance_ref = args.CONCEPTS.instance.Parse()
        return app_profiles.List(instance_ref)
 def testList(self):
     app_profiles_list = [self.msgs.AppProfile()]
     response = self.msgs.ListAppProfilesResponse(
         appProfiles=app_profiles_list)
     self.client.projects_instances_appProfiles.List.Expect(
         request=self.msgs.
         BigtableadminProjectsInstancesAppProfilesListRequest(
             parent=self.instance_relative_name),
         response=response)
     self.assertEquals(
         # Actual response from api_lib is a generator - realize into a list
         list(app_profiles.List(self.instance_ref)),
         app_profiles_list)