Skip to content

Commit 386b8e5

Browse files
authored
Fix flaky e2e test (#2622)
1 parent 3fb2497 commit 386b8e5

File tree

3 files changed

+7
-49
lines changed

3 files changed

+7
-49
lines changed

e2e/testdata/live-apply/json-output/config.yaml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@ kptArgs:
1818
- "--reconcile-timeout=1m"
1919
stdOut: |
2020
{"eventType":"resourceApplied","group":"","kind":"ConfigMap","name":"cm","namespace":"json-output","operation":"Created","timestamp":"<TIMESTAMP>","type":"apply"}
21-
{"eventType":"resourceApplied","group":"apps","kind":"Deployment","name":"third-nginx","namespace":"json-output","operation":"Created","timestamp":"<TIMESTAMP>","type":"apply"}
22-
{"configuredCount":0,"count":2,"createdCount":2,"eventType":"completed","failedCount":0,"serverSideCount":0,"timestamp":"<TIMESTAMP>","type":"apply","unchangedCount":0}
23-
{"eventType":"resourceApplied","group":"apps","kind":"Deployment","name":"fourth-nginx","namespace":"json-output","operation":"Created","timestamp":"<TIMESTAMP>","type":"apply"}
21+
{"configuredCount":0,"count":1,"createdCount":1,"eventType":"completed","failedCount":0,"serverSideCount":0,"timestamp":"<TIMESTAMP>","type":"apply","unchangedCount":0}
22+
{"eventType":"resourceApplied","group":"apps","kind":"Deployment","name":"nginx","namespace":"json-output","operation":"Created","timestamp":"<TIMESTAMP>","type":"apply"}
2423
{"configuredCount":0,"count":1,"createdCount":1,"eventType":"completed","failedCount":0,"serverSideCount":0,"timestamp":"<TIMESTAMP>","type":"apply","unchangedCount":0}
2524
{"eventType":"resourcePruned","group":"apps","kind":"Deployment","name":"second-nginx","namespace":"json-output","operation":"Pruned","timestamp":"<TIMESTAMP>","type":"prune"}
2625
{"eventType":"completed","pruned":1,"skipped":0,"timestamp":"<TIMESTAMP>","type":"prune"}
@@ -32,9 +31,5 @@ inventory:
3231
namespace: json-output
3332
- group: apps
3433
kind: Deployment
35-
name: third-nginx
36-
namespace: json-output
37-
- group: apps
38-
kind: Deployment
39-
name: fourth-nginx
34+
name: nginx
4035
namespace: json-output

e2e/testdata/live-apply/json-output/resources/third.yaml renamed to e2e/testdata/live-apply/json-output/resources/dep.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,19 @@
1515
apiVersion: apps/v1
1616
kind: Deployment
1717
metadata:
18-
name: third-nginx
18+
name: nginx
1919
namespace: json-output
2020
annotations:
21-
config.k8s.io/owning-inventory: json-output
21+
config.kubernetes.io/depends-on: apps/namespaces/json-output/ConfigMap/cm
2222
spec:
2323
replicas: 1
2424
selector:
2525
matchLabels:
26-
app: third-nginx
26+
app: nginx
2727
template:
2828
metadata:
2929
labels:
30-
app: third-nginx
30+
app: nginx
3131
spec:
3232
containers:
3333
- name: nginx

e2e/testdata/live-apply/json-output/resources/fourth.yaml

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)