jedcunningham commented on code in PR #29214:
URL: https://github.com/apache/airflow/pull/29214#discussion_r1091240925
##########
tests/charts/test_basic_helm_chart.py:
##########
@@ -508,3 +508,35 @@ def test_invalid_dags_access_mode(self):
def test_namespace_names(self, namespace):
"""Test various namespace names to make sure they render correctly in
templates"""
render_chart(namespace=namespace)
+
+
+ def test_postgres_connection_url_no_override(self):
+ # no nameoverride provided
+ assert
"postgresql://postgres:[email protected]:5432/postgres?sslmode=disable"
== \
+ render_chart(
+ "my-release",
+ values={
+ "postgresql": {
+ "enabled": True,
+ }
+ },
+ show_only=[
+ "templates/secrets/metadata-connection-secret.yaml"
+ ]
+ )["data"]["connection"]
Review Comment:
```suggestion
doc = render_chart(
"my-release",
show_only=["templates/secrets/metadata-connection-secret.yaml"]
)[0]
assert
"postgresql://postgres:[email protected]:5432/postgres?sslmode=disable"
== \
doc["data"]["connection"]
```
Doing something like this would make this easier to read. Note, I omitted
the `postgres.enabled` flag, it's already true.
--
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]