Add AWS_CONFIG_FILE to the environment variables

Turns out there is an additional environment variable AWS_CONFIG_FILE,
which gets evaluated for finding configuration files as well. This
commit adds support for it.
This commit is contained in:
Daniel Roschka 2016-12-30 10:39:38 +01:00
parent b0d4cdb1ee
commit 0fd09bf67a
2 changed files with 5 additions and 3 deletions

View file

@ -19,8 +19,10 @@ def test_get_aws_credentials_file_from_env(monkeypatch):
assert get_aws_credential_files_from_env() == {'/foo', '/bar'}
monkeypatch.setenv('BOTO_CONFIG', '/baz')
assert get_aws_credential_files_from_env() == {'/foo', '/bar', '/baz'}
monkeypatch.setenv('AWS_CONFIG_FILE', '/xxx')
assert get_aws_credential_files_from_env() == {'/foo', '/bar', '/baz', '/xxx'}
monkeypatch.setenv('AWS_DUMMY_KEY', 'foobar')
assert get_aws_credential_files_from_env() == {'/foo', '/bar', '/baz'}
assert get_aws_credential_files_from_env() == {'/foo', '/bar', '/baz', '/xxx'}
def test_get_aws_secrets_from_env(monkeypatch):