(t *testing.T, cluster *Cluster, pgSpec *acidv1.PostgresSpec, listOptions metav1.ListOptions)
| 768 | } |
| 769 | |
| 770 | func patchPostgresqlStreams(t *testing.T, cluster *Cluster, pgSpec *acidv1.PostgresSpec, listOptions metav1.ListOptions) (streams *zalandov1.FabricEventStreamList) { |
| 771 | patchData, err := specPatch(pgSpec) |
| 772 | assert.NoError(t, err) |
| 773 | |
| 774 | pgPatched, err := cluster.KubeClient.Postgresqls(namespace).Patch( |
| 775 | context.TODO(), cluster.Name, types.MergePatchType, patchData, metav1.PatchOptions{}, "spec") |
| 776 | assert.NoError(t, err) |
| 777 | |
| 778 | cluster.Postgresql.Spec = pgPatched.Spec |
| 779 | err = cluster.syncStream(appId) |
| 780 | assert.NoError(t, err) |
| 781 | |
| 782 | streams, err = cluster.KubeClient.FabricEventStreams(namespace).List(context.TODO(), listOptions) |
| 783 | assert.NoError(t, err) |
| 784 | |
| 785 | return streams |
| 786 | } |
| 787 | |
| 788 | func TestDeleteStreams(t *testing.T) { |
| 789 | pg.Name = fmt.Sprintf("%s-4", pg.Name) |
no test coverage detected