func (j *TestJig) CreatePDB(rc *v1.ReplicationController) (*policyv1beta1.PodDisruptionBudget, error) {
	pdb := j.newPDBTemplate(rc)
	newPdb, err := j.Client.PolicyV1beta1().PodDisruptionBudgets(j.Namespace).Create(context.TODO(), pdb, metav1.CreateOptions{})
	if err != nil {
		return nil, fmt.Errorf("failed to create PDB %q %v", pdb.Name, err)
	}
	if err := j.waitForPdbReady(); err != nil {
		return nil, fmt.Errorf("failed waiting for PDB to be ready: %v", err)
	}

	return newPdb, nil
}
// CreatePDB returns a PodDisruptionBudget for the given ReplicationController, or returns an error if a PodDisruptionBudget isn't ready
CreatePDB returns a PodDisruptionBudget for the given ReplicationController, or returns an error if a PodDisruptionBudget isn't ready
// CreatePDB returns a PodDisruptionBudget for the given ReplicationController or returns an error if a PodDisruptionBudget isn ' t ready
func (j *TestJig) CreatePDB(rc *v1.ReplicationController) (*policyv1beta1.PodDisruptionBudget, error) {
	pdb := j.newPDBTemplate(rc)
	newPdb, err := j.Client.PolicyV1beta1().PodDisruptionBudgets(j.Namespace).Create(context.TODO(), pdb, metav1.CreateOptions{})
	if err != nil {
		return nil, fmt.Errorf("failed to create PDB %q %v", pdb.Name, err)
	}
	if err := j.waitForPdbReady(); err != nil {
		return nil, fmt.Errorf("failed waiting for PDB to be ready: %v", err)
	}
	return newPdb, nil
}
func ( j * TestJig ) CreatePDB ( rc * v1 . ReplicationController ) ( * policyv1beta1 . PodDisruptionBudget , error ) { pdb := j . newPDBTemplate ( rc ) newPdb , err := j . Client . PolicyV1beta1 ( ) . PodDisruptionBudgets ( j . Namespace ) . Create ( context . TODO ( ) , pdb , metav1 . CreateOptions { } ) if err != nil { return nil , fmt . Errorf ( " " , pdb . Name , err ) } if err := j . waitForPdbReady ( ) ; err != nil { return nil , fmt . Errorf ( " " , err ) } return newPdb , nil }
CreatePDB returns a PodDisruptionBudget for the given ReplicationController, or returns an error if a PodDisruptionBudget isn't ready
CreatePDB returns a PodDisruptionBudget for the given ReplicationController or returns an error if a PodDisruptionBudget isn ' t ready