@@ -41,12 +41,12 @@ def tearDownClass(cls):
4141
4242 def test_create_apps_deployment_from_yaml (self ):
4343 """
44- Should be able to create an apps/v1beta1 deployment.
44+ Should be able to create an apps/v1 deployment.
4545 """
4646 k8s_client = client .api_client .ApiClient (configuration = self .config )
4747 utils .create_from_yaml (
4848 k8s_client , self .path_prefix + "apps-deployment.yaml" )
49- app_api = client .AppsV1beta1Api (k8s_client )
49+ app_api = client .AppsV1Api (k8s_client )
5050 dep = app_api .read_namespaced_deployment (name = "nginx-app" ,
5151 namespace = "default" )
5252 self .assertIsNotNone (dep )
@@ -68,7 +68,7 @@ def test_create_apps_deployment_from_yaml_obj(self):
6868
6969 utils .create_from_dict (k8s_client , yml_obj )
7070
71- app_api = client .AppsV1beta1Api (k8s_client )
71+ app_api = client .AppsV1Api (k8s_client )
7272 dep = app_api .read_namespaced_deployment (name = "nginx-app-3" ,
7373 namespace = "default" )
7474 self .assertIsNotNone (dep )
@@ -289,7 +289,7 @@ def test_create_from_list_in_multi_resource_yaml(self):
289289 utils .create_from_yaml (
290290 k8s_client , self .path_prefix + "multi-resource-with-list.yaml" )
291291 core_api = client .CoreV1Api (k8s_client )
292- app_api = client .AppsV1beta1Api (k8s_client )
292+ app_api = client .AppsV1Api (k8s_client )
293293 pod_0 = core_api .read_namespaced_pod (
294294 name = "mock-pod-0" , namespace = "default" )
295295 self .assertIsNotNone (pod_0 )
@@ -365,15 +365,16 @@ def test_create_from_multi_resource_yaml_with_multi_conflicts(self):
365365 name = "triple-nginx" , namespace = "default" ,
366366 body = {})
367367
368- def test_create_namespaces_apps_deployment_from_yaml (self ):
368+ def test_create_namespaced_apps_deployment_from_yaml (self ):
369369 """
370- Should be able to create an apps/v1beta1 deployment.
370+ Should be able to create an apps/v1beta1 deployment
371+ in a test namespace.
371372 """
372373 k8s_client = client .api_client .ApiClient (configuration = self .config )
373374 utils .create_from_yaml (
374375 k8s_client , self .path_prefix + "apps-deployment.yaml" ,
375376 namespace = self .test_namespace )
376- app_api = client .AppsV1beta1Api (k8s_client )
377+ app_api = client .AppsV1Api (k8s_client )
377378 dep = app_api .read_namespaced_deployment (name = "nginx-app" ,
378379 namespace = self .test_namespace )
379380 self .assertIsNotNone (dep )
@@ -391,7 +392,7 @@ def test_create_from_list_in_multi_resource_yaml_namespaced(self):
391392 k8s_client , self .path_prefix + "multi-resource-with-list.yaml" ,
392393 namespace = self .test_namespace )
393394 core_api = client .CoreV1Api (k8s_client )
394- app_api = client .AppsV1beta1Api (k8s_client )
395+ app_api = client .AppsV1Api (k8s_client )
395396 pod_0 = core_api .read_namespaced_pod (
396397 name = "mock-pod-0" , namespace = self .test_namespace )
397398 self .assertIsNotNone (pod_0 )
0 commit comments