Skip to content

Commit 0cfddb3

Browse files
committed
Revert "temp: Skip integration test run due to time"
This reverts commit 9e35d8a.
1 parent 9e35d8a commit 0cfddb3

File tree

1 file changed

+54
-54
lines changed

1 file changed

+54
-54
lines changed

.github/workflows/build.yml

Lines changed: 54 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -161,61 +161,61 @@ jobs:
161161
# run integration tests on the oldest and newest supported versions of python.
162162
# we don't run on the entire matrix to avoid a 3xN set of concurrent tests against
163163
# the target server where N is the number of supported python versions.
164-
# - name: run-integration-tests
165-
# shell: bash
164+
- name: run-integration-tests
165+
shell: bash
166166

167-
# # keep versions consistent with the first and last from the strategy matrix
168-
# if: ${{ (contains(fromJSON('["3.9"]'), matrix.python) || contains(fromJSON('["3.13"]'), matrix.python)) && steps.secret-check.outputs.secrets_available == 'true'}}
169-
# run: |
170-
# # decrypt the encrypted test synapse configuration
171-
# openssl aes-256-cbc -K ${{ secrets.encrypted_d17283647768_key }} -iv ${{ secrets.encrypted_d17283647768_iv }} -in test.synapseConfig.enc -out test.synapseConfig -d
172-
# mv test.synapseConfig ~/.synapseConfig
173-
174-
# if [ "${{ startsWith(matrix.os, 'ubuntu') }}" == "true" ]; then
175-
# # on linux only we can build and run a docker container to serve as an SFTP host for our SFTP tests.
176-
# # Docker is not available on GH Action runners on Mac and Windows.
177-
178-
# docker build -t sftp_tests - < tests/integration/synapseclient/core/upload/Dockerfile_sftp
179-
# docker run -d sftp_tests:latest
180-
181-
# # get the internal IP address of the just launched container
182-
# export SFTP_HOST=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -q))
183-
184-
# printf "[sftp://$SFTP_HOST]\nusername: test\npassword: test\n" >> ~/.synapseConfig
185-
186-
# # add to known_hosts so the ssh connections can be made without any prompting/errors
187-
# mkdir -p ~/.ssh
188-
# ssh-keyscan -H $SFTP_HOST >> ~/.ssh/known_hosts
189-
# fi
190-
191-
# # set env vars used in external bucket tests from secrets
192-
# export EXTERNAL_S3_BUCKET_NAME="${{secrets.EXTERNAL_S3_BUCKET_NAME}}"
193-
# export EXTERNAL_S3_BUCKET_AWS_ACCESS_KEY_ID="${{secrets.EXTERNAL_S3_BUCKET_AWS_ACCESS_KEY_ID}}"
194-
# export EXTERNAL_S3_BUCKET_AWS_SECRET_ACCESS_KEY="${{secrets.EXTERNAL_S3_BUCKET_AWS_SECRET_ACCESS_KEY}}"
195-
# if [ ${{ steps.otel-check.outputs.run_opentelemetry }} == "true" ]; then
196-
# # Set to 'file' to enable OpenTelemetry export to file
197-
# export SYNAPSE_OTEL_INTEGRATION_TEST_EXPORTER="file"
198-
# fi
199-
200-
# # use loadscope to avoid issues running tests concurrently that share scoped fixtures
201-
# pytest -sv --reruns 3 --cov-append --cov=. --cov-report xml tests/integration -n 8 --ignore=tests/integration/synapseclient/test_command_line_client.py --dist loadscope
202-
203-
# # Execute the CLI tests in a non-dist way because they were causing some test instability when being run concurrently
204-
# pytest -sv --reruns 3 --cov-append --cov=. --cov-report xml tests/integration/synapseclient/test_command_line_client.py
205-
# - name: Upload otel spans
206-
# uses: actions/upload-artifact@v4
207-
# if: always()
208-
# with:
209-
# name: otel_spans_integration_testing_${{ matrix.os }}
210-
# path: tests/integration/otel_spans_integration_testing_*.ndjson
211-
# if-no-files-found: ignore
212-
# - name: Upload coverage report
213-
# id: upload_coverage_report
214-
# uses: actions/upload-artifact@v4
215-
# if: ${{ contains(fromJSON('["3.13"]'), matrix.python) && contains(fromJSON('["ubuntu-22.04"]'), matrix.os)}}
216-
# with:
217-
# name: coverage-report
218-
# path: coverage.xml
167+
# keep versions consistent with the first and last from the strategy matrix
168+
if: ${{ (contains(fromJSON('["3.9"]'), matrix.python) || contains(fromJSON('["3.13"]'), matrix.python)) && steps.secret-check.outputs.secrets_available == 'true'}}
169+
run: |
170+
# decrypt the encrypted test synapse configuration
171+
openssl aes-256-cbc -K ${{ secrets.encrypted_d17283647768_key }} -iv ${{ secrets.encrypted_d17283647768_iv }} -in test.synapseConfig.enc -out test.synapseConfig -d
172+
mv test.synapseConfig ~/.synapseConfig
173+
174+
if [ "${{ startsWith(matrix.os, 'ubuntu') }}" == "true" ]; then
175+
# on linux only we can build and run a docker container to serve as an SFTP host for our SFTP tests.
176+
# Docker is not available on GH Action runners on Mac and Windows.
177+
178+
docker build -t sftp_tests - < tests/integration/synapseclient/core/upload/Dockerfile_sftp
179+
docker run -d sftp_tests:latest
180+
181+
# get the internal IP address of the just launched container
182+
export SFTP_HOST=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' $(docker ps -q))
183+
184+
printf "[sftp://$SFTP_HOST]\nusername: test\npassword: test\n" >> ~/.synapseConfig
185+
186+
# add to known_hosts so the ssh connections can be made without any prompting/errors
187+
mkdir -p ~/.ssh
188+
ssh-keyscan -H $SFTP_HOST >> ~/.ssh/known_hosts
189+
fi
190+
191+
# set env vars used in external bucket tests from secrets
192+
export EXTERNAL_S3_BUCKET_NAME="${{secrets.EXTERNAL_S3_BUCKET_NAME}}"
193+
export EXTERNAL_S3_BUCKET_AWS_ACCESS_KEY_ID="${{secrets.EXTERNAL_S3_BUCKET_AWS_ACCESS_KEY_ID}}"
194+
export EXTERNAL_S3_BUCKET_AWS_SECRET_ACCESS_KEY="${{secrets.EXTERNAL_S3_BUCKET_AWS_SECRET_ACCESS_KEY}}"
195+
if [ ${{ steps.otel-check.outputs.run_opentelemetry }} == "true" ]; then
196+
# Set to 'file' to enable OpenTelemetry export to file
197+
export SYNAPSE_OTEL_INTEGRATION_TEST_EXPORTER="file"
198+
fi
199+
200+
# use loadscope to avoid issues running tests concurrently that share scoped fixtures
201+
pytest -sv --reruns 3 --cov-append --cov=. --cov-report xml tests/integration -n 8 --ignore=tests/integration/synapseclient/test_command_line_client.py --dist loadscope
202+
203+
# Execute the CLI tests in a non-dist way because they were causing some test instability when being run concurrently
204+
pytest -sv --reruns 3 --cov-append --cov=. --cov-report xml tests/integration/synapseclient/test_command_line_client.py
205+
- name: Upload otel spans
206+
uses: actions/upload-artifact@v4
207+
if: always()
208+
with:
209+
name: otel_spans_integration_testing_${{ matrix.os }}
210+
path: tests/integration/otel_spans_integration_testing_*.ndjson
211+
if-no-files-found: ignore
212+
- name: Upload coverage report
213+
id: upload_coverage_report
214+
uses: actions/upload-artifact@v4
215+
if: ${{ contains(fromJSON('["3.13"]'), matrix.python) && contains(fromJSON('["ubuntu-22.04"]'), matrix.os)}}
216+
with:
217+
name: coverage-report
218+
path: coverage.xml
219219

220220
sonarcloud:
221221
needs: [test]

0 commit comments

Comments
 (0)