Esempio n. 1
0
 def test_path_exists_rc(self):
     client = KubernetesClient()
     rc = client.get_replication_controllers()
     rc1 = rc[0]
     kp = KubePath()
     kp.parse_path('/default/rc/%s/describe' % rc1)
     assert_that(kp.exists(client), is_(True))
Esempio n. 2
0
 def test_list_files_for_rc(self):
     client = KubernetesClient()
     fs = KubeFileSystem(client)
     rc = client.get_replication_controllers()[0]
     path = '/default/rc/%s' % rc
     files = fs.list_files(path)
     assert_that(files, has_items('describe', 'json', 'yaml'))
     assert_that(len(files), is_(3))
Esempio n. 3
0
 def test_list_files_for_rc(self):
     client = KubernetesClient()
     fs = KubeFileSystem(client)
     rc = client.get_replication_controllers()[0]
     path = '/default/rc/%s' % rc
     files = fs.list_files(path)
     assert_that(files, has_items('describe', 'json', 'yaml'))
     assert_that(len(files), is_(3))
Esempio n. 4
0
 def test_get_replication_controllers(self):
     client = KubernetesClient()
     rc = client.get_replication_controllers('default')
     assert_that(len(rc), is_(3))
Esempio n. 5
0
 def test_get_replication_controllers(self):
     client = KubernetesClient()
     rc = client.get_replication_controllers('default')
     assert_that(len(rc), is_(3))