Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .evergreen/orchestration/drivers_orchestration.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ def run(opts):
expansion_yaml.unlink(missing_ok=True)
expansion_sh = Path("mo-expansion.sh")
expansion_sh.unlink(missing_ok=True)
uri_txt = DRIVERS_TOOLS / "uri.txt"

# The evergreen directory to path.
os.environ["PATH"] = f"{EVG_PATH}:{os.environ['PATH']}"
Expand Down Expand Up @@ -298,6 +299,7 @@ def run(opts):
# Handle the cluster uri.
uri = resp.get("mongodb_auth_uri", resp["mongodb_uri"])
expansion_yaml.write_text(expansion_yaml.read_text() + f"\nMONGODB_URI: {uri}")
uri_txt.write_text(uri)
LOGGER.info(f"Cluster URI: {uri}")

# Write the results file.
Expand Down
21 changes: 20 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ on:
branches:
- "master"

concurrency:
group: tests-${{ github.ref }}
cancel-in-progress: true

defaults:
run:
shell: bash -eux {0}

jobs:
tests:
name: "Tests"
Expand Down Expand Up @@ -41,14 +49,25 @@ jobs:
fetch-depth: 2

- id: setup-mongodb
name: "Test GitHub Action"
name: "Run GitHub Action"
uses: ./
with:
version: ${{ matrix.mongodb-version }}
topology: ${{ matrix.topology }}
auth: ${{ matrix.auth }}
ssl: ${{ matrix.ssl }}

- id: test-mongodb
name: "Test GitHub Action"
run: |
chmod +x mongodb/bin/mongosh
URI=$(cat uri.txt)
ARGS=""
if [ ${{ matrix.ssl }} == "ssl" ]; then
ARGS="--tls --tlsCertificateKeyFile $(pwd)/.evergreen/x509gen/client.pem --tlsCAFile $(pwd)/.evergreen/x509gen/ca.pem"
fi
mongodb/bin/mongosh $URI $ARGS --eval "db.runCommand({ ping: 1 })"

pre-commit:
runs-on: ubuntu-latest
steps:
Expand Down
Loading