File tree Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Original file line number Diff line number Diff line change @@ -545,6 +545,8 @@ functions:
545
545
546
546
set -o errexit
547
547
set -o xtrace
548
+
549
+ source ./secrets-export.sh
548
550
bash ${PROJECT_DIRECTORY}/.evergreen/tox.sh ${PYTHON_BINARY} -m test-atlas
549
551
550
552
" add aws auth variables to file " :
@@ -774,18 +776,31 @@ functions:
774
776
- command : ec2.assume_role
775
777
params :
776
778
role_arn : ${aws_test_secrets_role}
779
+ - command : shell.exec
780
+ type : test
781
+ params :
782
+ working_dir : " src"
783
+ silent : true
784
+ script : |
785
+ # DO NOT ECHO WITH XTRACE (which PREPARE_SHELL does)
786
+ export AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID}
787
+ export AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY}
788
+ export AWS_SESSION_TOKEN=${AWS_SESSION_TOKEN}
777
789
- command : shell.exec
778
790
type : test
779
791
params :
780
792
working_dir : " src"
781
793
shell : bash
782
794
script : |
783
795
${PREPARE_SHELL}
784
- bash ${PROJECT_DIRECTORY}/.evergreen/tox.sh ${PYTHON_BINARY} -m aws-secrets
796
+
797
+ # This is required for pypy3.7 UTF encoding
798
+ export LC_ALL=en_US.UTF-8
799
+ bash ${PROJECT_DIRECTORY}/.evergreen/tox.sh ${PYTHON_BINARY} -m aws-secrets -- drivers/test
785
800
786
801
- command : expansions.update
787
802
params :
788
- file : secrets-expansion.yml
803
+ file : src/ secrets-expansion.yml
789
804
790
805
" run oidc auth test with aws credentials " :
791
806
- command : shell.exec
Original file line number Diff line number Diff line change @@ -148,10 +148,8 @@ commands =
148
148
deps =
149
149
pytest>=7
150
150
passenv = *
151
- allowlist_externals =
152
- bash
153
151
commands =
154
- bash -c ' source ./secrets-export.sh; python -m pytest -v {posargs} ./test/atlas/test_connection.py'
152
+ python -m pytest -v {posargs} ./test/atlas/test_connection.py
155
153
156
154
[testenv:test-mockupdb]
157
155
description = run mockupdb tests
@@ -170,7 +168,7 @@ passenv = *
170
168
allowlist_externals =
171
169
bash
172
170
commands =
173
- python {env:DRIVERS_TOOLS}/.evergreen/auth_aws/setup_secrets.py drivers/test
171
+ python {env:DRIVERS_TOOLS}/.evergreen/auth_aws/setup_secrets.py {posargs}
174
172
175
173
[testenv:test-aws-secrets]
176
174
deps =
You can’t perform that action at this time.
0 commit comments