jedcunningham commented on a change in pull request #20609:
URL: https://github.com/apache/airflow/pull/20609#discussion_r786178921



##########
File path: chart/tests/test_airflow_common.py
##########
@@ -248,3 +248,22 @@ def test_have_all_variables(self):
             assert variables == jmespath.search(
                 "spec.template.spec.containers[0].env[*].name", doc
             ), f"Wrong vars in {component}"
+
+    def test_have_all_config_mounts_on_init_containers(self, 
expected_read_only):
+        docs = render_chart(
+            values={},
+            show_only=[
+                "templates/scheduler/scheduler-deployment.yaml",
+                "templates/workers/worker-deployment.yaml",
+                "templates/webserver/webserver-deployment.yaml",
+                "templates/triggerer/triggerer-deployment.yaml",
+            ],
+        )
+        assert 4 == len(docs)
+        for doc in docs:
+            expected_mount = {
+                "subPath": "airflow.cfg",
+                "name": "config",
+                "readOnly": expected_read_only,
+            }

Review comment:
       ```suggestion
           expected_mount = {
               "subPath": "airflow.cfg",
               "name": "config",
               "readOnly": True,
               "mountPath": "something",
           }
           for doc in docs:
   ```
   
   We aren't passing in `expected_read_only`, and we don't need to set this in 
every loop. We do need to set the mountPath (not sure what it would be off the 
top of my head).

##########
File path: chart/tests/test_airflow_common.py
##########
@@ -248,3 +248,22 @@ def test_have_all_variables(self):
             assert variables == jmespath.search(
                 "spec.template.spec.containers[0].env[*].name", doc
             ), f"Wrong vars in {component}"
+
+    def test_have_all_config_mounts_on_init_containers(self, 
expected_read_only):

Review comment:
       ```suggestion
       def test_have_all_config_mounts_on_init_containers(self):
   ```




-- 
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]


Reply via email to