File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -167,10 +167,13 @@ jobs:
167167 kubectl logs -n otterize-system -l app=otterize-network-mapper --tail=-1
168168
169169 echo "export intents and compare to expected file"
170- otterize network-mapper export --telemetry-enabled=false -n otterize-tutorial-kafka-mapping --format=json | jq 'sort_by(.metadata.namespace + .metadata.name) | map(.spec.targets |= (sort_by(keys_unsorted[0]) | map(if .kafka? then .kafka.topics |= map(.operations |= sort) else . end)))' > /tmp/intents.json
171- diff .github/workflows/tests-expected-results/kafka-tutorial-intents.json /tmp/intents.json
170+ INTENTS_JSON=`otterize network-mapper export --telemetry-enabled=false -n otterize-tutorial-kafka-mapping --format=json`
171+ INTENTS_JSON_NO_KIND=`echo "$INTENTS_JSON" | jq 'map(del(.spec.workload.kind))'`
172+ INTENTS_JSON_NO_KIND_AND_SORTED=`echo "$INTENTS_JSON_NO_KIND" | jq 'sort_by(.metadata.namespace + .metadata.name) | map(.spec.targets |= (sort_by(keys_unsorted[0]) | map(if .kafka? then .kafka.topics |= map(.operations |= sort) else . end)))'`
173+ echo "$INTENTS_JSON_NO_KIND_AND_SORTED" > /tmp/intents.json
172174 echo "expected" && cat .github/workflows/tests-expected-results/kafka-tutorial-intents.json
173175 echo "actual" && cat /tmp/intents.json
176+ diff .github/workflows/tests-expected-results/kafka-tutorial-intents.json /tmp/intents.json
174177
175178 e2e-test :
176179 needs :
Original file line number Diff line number Diff line change 99 },
1010 "spec" : {
1111 "workload" : {
12- "name" : " client" ,
13- "kind" : " Deployment"
12+ "name" : " client"
1413 },
1514 "targets" : [
1615 {
5049 },
5150 "spec" : {
5251 "workload" : {
53- "name" : " client-2" ,
54- "kind" : " Deployment"
52+ "name" : " client-2"
5553 },
5654 "targets" : [
5755 {
You can’t perform that action at this time.
0 commit comments