fix e2e tests
This commit is contained in:
		
							parent
							
								
									8cb46cf37b
								
							
						
					
					
						commit
						ab8e8dc06a
					
				|  | @ -506,14 +506,10 @@ class EndToEndTestCase(unittest.TestCase): | ||||||
| 
 | 
 | ||||||
|         pg_crd_annotations = { |         pg_crd_annotations = { | ||||||
|             "metadata": { |             "metadata": { | ||||||
|                 "annotations": [ |                 "annotations": { | ||||||
|                     { |                     "deployment-time": "2020-04-30 12:00:00", | ||||||
|                         "deployment-time": "2020-04-30 12:00:00", |                     "downscaler/downtime_replicas": "0", | ||||||
|                     }, |                 }, | ||||||
|                     { |  | ||||||
|                         "downscaler/downtime_replicas": "0", |  | ||||||
|                     }, |  | ||||||
|                 ], |  | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|         k8s.api.custom_objects_api.patch_namespaced_custom_object( |         k8s.api.custom_objects_api.patch_namespaced_custom_object( | ||||||
|  | @ -732,7 +728,7 @@ class K8s: | ||||||
|     def check_service_annotations(self, svc_labels, annotations, namespace='default'): |     def check_service_annotations(self, svc_labels, annotations, namespace='default'): | ||||||
|         svcs = self.api.core_v1.list_namespaced_service(namespace, label_selector=svc_labels, limit=1).items |         svcs = self.api.core_v1.list_namespaced_service(namespace, label_selector=svc_labels, limit=1).items | ||||||
|         for svc in svcs: |         for svc in svcs: | ||||||
|             if len(svc.metadata.annotations) != len(annotations): |             if len(svc.metadata.annotations) < len(annotations): | ||||||
|                 return False |                 return False | ||||||
|             for key in svc.metadata.annotations: |             for key in svc.metadata.annotations: | ||||||
|                 if svc.metadata.annotations[key] != annotations[key]: |                 if svc.metadata.annotations[key] != annotations[key]: | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue