jedcunningham commented on a change in pull request #22323:
URL: https://github.com/apache/airflow/pull/22323#discussion_r835622010
##########
File path: tests/charts/test_scheduler.py
##########
@@ -518,3 +518,11 @@ def test_log_groomer_resources(self):
"memory": "2Gi",
},
} == jmespath.search("spec.template.spec.containers[1].resources",
docs[0])
+
+ def test_dags_persistence_subpath(self):
+ docs = render_chart(
+ values={"dags": {"persistence": {"enabled": True, "subPath":
"test/dags"}}},
+ show_only=["templates/scheduler/scheduler-deployment.yaml"],
+ )
+
+ assert "dags" in
jmespath.search("spec.template.spec.containers[0].volumeMounts[*].name",
docs[0])
Review comment:
This isn't a "good" assertion, as it would pass without any of your
subpath template changes, or even without subPath in the values in this test.
Try something like this instead:
```suggestion
assert "test/dags" in
jmespath.search("spec.template.spec.containers[0].volumeMounts[?name ==
'dags'].subPath", docs[0])
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]