ashb commented on code in PR #74542:
URL: https://github.com/apache/airflow/pull/74542#discussion_r4250959938
##########
task-sdk/tests/task_sdk/definitions/_internal/test_templater.py:
##########
@@ -300,6 +308,115 @@ def
test_do_render_template_fields_renders_list_values(self):
assert parent.items == ["first", "second"]
+def _write_zip(path: Path, members: dict[str, str]) -> Path:
+ with zipfile.ZipFile(path, "w") as zf:
+ for name, content in members.items():
+ zf.writestr(name, content)
+ return path
+
+
+def _write_template_dir(path: Path, templates: dict[str, str]) -> Path:
+ path.mkdir()
+ for name, content in templates.items():
+ (path / name).write_text(content)
+ return path
+
+
+class TestCreateTemplateEnvZip:
Review Comment:
One test class per subject, not per area/feature we test.
i.e. move these to be in TestTemplater.
--
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]