Skip to content

Commit

Permalink
#57 Fixing lint (#61)
Browse files Browse the repository at this point in the history
  • Loading branch information
ome9ax authored Jul 18, 2022
1 parent 3e4ef78 commit 82fcd93
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1 +1 @@
include LICENSE, target_s3_jsonl/logging.conf
include requirements.txt LICENSE target_s3_jsonl/logging.conf
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ classifiers =
packages = find:
py_modules = target_s3_jsonl
python_requires = >=3.8
# install_requires = file: requirements.txt
install_requires =
jsonschema==4.7.2
boto3==1.24.28
Expand Down
2 changes: 0 additions & 2 deletions target_s3_jsonl/s3.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
#!/usr/bin/env python3
import os
import re
import time
import backoff
import boto3
from botocore.exceptions import ClientError
Expand Down
6 changes: 4 additions & 2 deletions tests/test_s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ def config_assume_role():
with open(Path('tests', 'resources', 'config_assume_role.json'), 'r', encoding='utf-8') as f:
return json.load(f)


@fixture(scope='module')
def aws_credentials():
"""Mocked AWS Credentials for moto."""
Expand All @@ -48,10 +49,11 @@ def test_log_backoff_attempt(caplog):
@mock_sts
@mock_s3
def test_create_client_with_assumed_role(config_assume_role, caplog):
"""Assert client is created with assumed role when role_arn is specified"""
client = create_client(config_assume_role)
"""Assert client is created with assumed role when role_arn is specified"""
create_client(config_assume_role)
assert caplog.text.endswith('Creating s3 client with role TestAssumeRole\n')


@mock_s3
def test_create_client(aws_credentials, config):
'''TEST : simple upload_files call'''
Expand Down

0 comments on commit 82fcd93

Please sign in to comment.