Ejemplo n.º 1
0
 def SetUp(self):
   self.app_profile_update_mock = self.StartObjectPatch(
       app_profiles,
       'Update',
       return_value=self.msgs.Operation(name='operations/operation-name'))
   self.app_profile_ref = util.GetAppProfileRef('my-instance',
                                                'my-app-profile')
Ejemplo n.º 2
0
 def SetUp(self):
     self.app_profile_ref = util.GetAppProfileRef('my-instance',
                                                  'my-app-profile')
     self.app_profile_describe_mock = self.StartObjectPatch(
         app_profiles,
         'Describe',
         return_value=self.msgs.AppProfile(name='my-app-profile'))
Ejemplo n.º 3
0
 def testCreateTransactional(self):
   self.Run('bigtable app-profiles create my-app-profile '
            '--instance my-instance --description my-description '
            '--route-to my-cluster --transactional-writes')
   self.app_profile_create_mock.assert_called_once_with(
       util.GetAppProfileRef('my-instance', 'my-app-profile'),
       cluster='my-cluster',
       description='my-description',
       multi_cluster=False,
       transactional_writes=True,
       force=False)
Ejemplo n.º 4
0
    def SetUp(self):
        self.instance_id = 'my-instance'
        self.app_profile_id = 'my-app-profile'
        self.cluster_id = 'my-cluster'

        self.instance_relative_name = 'projects/fake-project/instances/my-instance'
        self.app_profile_relative_name = (self.instance_relative_name +
                                          '/appProfiles/my-app-profile')

        self.app_profile_ref = util.GetAppProfileRef(self.instance_id,
                                                     self.app_profile_id)
        self.instance_ref = util.GetInstanceRef(self.instance_id)
Ejemplo n.º 5
0
 def SetUp(self):
   self.app_profile_delete_mock = self.StartObjectPatch(
       app_profiles, 'Delete', return_value=self.msgs.Empty())
   self.app_profile_ref = util.GetAppProfileRef('my-instance',
                                                'my-app-profile')