File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
flink-kubernetes-operator/src/test/java/org/apache/flink/kubernetes/operator/controller Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 6868import static org .apache .flink .kubernetes .operator .config .KubernetesOperatorConfigOptions .OPERATOR_JOB_UPGRADE_LAST_STATE_FALLBACK_ENABLED ;
6969import static org .apache .flink .kubernetes .operator .config .KubernetesOperatorConfigOptions .SNAPSHOT_RESOURCE_ENABLED ;
7070import static org .apache .flink .kubernetes .operator .utils .EventRecorder .Reason .ValidationError ;
71+ import static org .assertj .core .api .Assertions .assertThat ;
7172import static org .junit .jupiter .api .Assertions .assertEquals ;
7273import static org .junit .jupiter .api .Assertions .assertFalse ;
7374import static org .junit .jupiter .api .Assertions .assertNotEquals ;
@@ -934,7 +935,6 @@ public void cleanUpNewDeployment() {
934935 assertTrue (testController .getContextFactory ().getMetricGroups ().isEmpty ());
935936 }
936937
937- // todo add test here
938938 @ Test
939939 public void testIngressLifeCycle () throws Exception {
940940 FlinkDeployment appNoIngress = TestUtils .buildApplicationCluster ();
@@ -984,6 +984,9 @@ public void testIngressLifeCycle() throws Exception {
984984 appWithIngress .getMetadata ().getName (),
985985 appWithIngress .getMetadata ().getNamespace ())
986986 .getHost ());
987+ assertThat (ingress .getMetadata ().getOwnerReferences ()).hasSize (1 );
988+ assertThat (ingress .getMetadata ().getOwnerReferences ().get (0 ).getKind ())
989+ .isEqualTo (FlinkDeployment .class .getSimpleName ());
987990 }
988991
989992 @ Test
You can’t perform that action at this time.
0 commit comments