Skip to content

Commit

Permalink
clean up some flake8 linting flags
Browse files Browse the repository at this point in the history
  • Loading branch information
kimpham54 committed Dec 18, 2024
1 parent 9f4cb0d commit d59a03b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
1 change: 0 additions & 1 deletion src/jp2_remediator/processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ def process_directory(self, directory_path):
reader = self.box_reader_factory.get_reader(file_path)
reader.read_jp2_file()


def process_s3_bucket(self, bucket_name, prefix="", output_bucket_name=None, output_prefix=""):
"""Process all JP2 files in a given S3 bucket."""
s3 = boto3.client("s3")
Expand Down
5 changes: 2 additions & 3 deletions src/jp2_remediator/tests/unit/test_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,7 @@ def test_process_directory_with_multiple_files(
@patch("jp2_remediator.processor.boto3.client", autospec=True)
@patch("builtins.print", autospec=True)
def test_process_s3_bucket_with_output_options(
self, mock_print, mock_boto3_client, processor, mock_box_reader_factory
):
self, mock_print, mock_boto3_client, processor, mock_box_reader_factory):
# Ensure processor is the actual Processor object
assert hasattr(processor, "process_s3_bucket"), "Processor object expected"
# Set up the mock S3 client
Expand Down Expand Up @@ -130,4 +129,4 @@ def test_process_s3_bucket_with_output_options(
unittest.mock.call(f"Processing file: file1.jp2 from bucket {bucket_name}"),
unittest.mock.call(f"Processing file: file2.jp2 from bucket {bucket_name}"),
]
mock_print.assert_has_calls(expected_print_calls, any_order=True)
mock_print.assert_has_calls(expected_print_calls, any_order=True)

0 comments on commit d59a03b

Please sign in to comment.