anisayakmitra-in commented on PR #77626:
URL: https://github.com/apache/airflow/pull/77626#issuecomment-7212974548
Thanks for the detailed review @o-nikolas! I have updated the PR to address
all four comments:
1. **`test_app.py` (`test_downloads_dags_and_skips_directories`)**: Isolated
`AIRFLOW__CORE__DAGS_FOLDER` with `monkeypatch.setenv(...)` before calling
`fetch_dags_from_s3`, patched `app.mkdtemp` to return `str(tmp_path)`, and
added exact assertions on `mkdtemp`,
`mock_bucket.download_file("dags/my_dag.py", str(tmp_path / "my_dag.py"))`, and
`app.os.environ["AIRFLOW__CORE__DAGS_FOLDER"] == str(tmp_path)`.
2. **`test_app.py` (`test_subprocess_exception_reports_return_code_one`)**:
Added `mock_subprocess_run.assert_called_once_with("echo test", check=False,
shell=True, stdout=app.subprocess.PIPE, stderr=app.subprocess.STDOUT)` to
verify `shell=True` for string commands.
3. **`ruff check` & `ruff format`**: Collapsed the multi-line `assert
app.get_queue_url() == ...` assertions in `TestGetQueueUrl` onto single lines,
and removed the `datetime.timezone.utc` (`UP017`) / unused imports in
`test_utils.py`.
4. **`test_utils.py`**: Removed `TestAwsLambdaUtilsConstants` and
`TestLambdaQueuedTask` while keeping `TestConfigKeys` covering
`[aws_lambda_executor]` config option keys.
Validated locally with `ruff check`, `ruff format --check`, and `pytest` (13
passed). Could you please approve the CI workflow run and take another look
when convenient?
--
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]