@@ -11,7 +11,7 @@ permissions:
1111name : encryption-tests
1212
1313jobs :
14- ssdlc :
14+ set-up :
1515 permissions :
1616 # required for all workflows
1717 security-events : write
@@ -24,52 +24,61 @@ jobs:
2424
2525 - name : Set-up cluster
2626 - shell : bash
27-
2827
29-
30-
31- - name : Run tests
32- uses : mongodb-labs/drivers-github-tools/node/get_version_info@v2
33- with :
34- npm_package_name : mongodb
35-
36- - name : actions/compress_sign_and_upload
37- uses : mongodb-labs/drivers-github-tools/node/sign_node_package@v2
38- with :
39- aws_role_arn : ${{ secrets.AWS_ROLE_ARN }}
40- aws_region_name : us-east-1
41- aws_secret_id : ${{ secrets.AWS_SECRET_ID }}
42- npm_package_name : mongodb
43- dry_run : ${{ needs.release_please.outputs.release_created == '' }}
44-
45- - name : Copy sbom file to release assets
46- shell : bash
47- if : ${{ '' == '' }}
48- run : cp sbom.json ${{ env.S3_ASSETS }}/sbom.json
49-
50- # only used for mongodb-client-encryption
51- - name : Augment SBOM and copy to release assets
52- if : ${{ '' != '' }}
53- uses : mongodb-labs/drivers-github-tools/sbom@v2
54- with :
55- silk_asset_group : ' '
56- sbom_file_name : sbom.json
57-
58- - name : Generate authorized pub report
59- uses : mongodb-labs/drivers-github-tools/full-report@v2
28+ run-tests :
29+ needs :
30+ - set-up
31+ runs-on : ${{ matrix.os }}
32+ strategy :
33+ fail-fast : false
34+ matrix :
35+ node : [20]
36+ os : [ubuntu-latest]
37+ mongodb : [8.0.0]
38+ # clone drivers-evergreen-tools (will delete itself once the run is over)
39+ git clone --depth=1 https://github.com/mongodb-labs/drivers-evergreen-tools.git /data/mci/ead9f9a67ef900991e09bd9589dfee0e/drivers-tools
40+ # set path
41+ # calling run orchestration sets up a server on your computer
42+ # it outputs relevants uri in expansions.yml
43+ # put uri into an environment variable
44+ - name : set-up-orchestration
45+ - command : subprocess.exec
46+ params :
47+ binary : bash
48+ add_expansions_to_env : true
49+ env :
50+ # The following is the settings for how we want to launch mongodb
51+ MONGODB_VERSION : ${VERSION}
52+ TOPOLOGY : ${TOPOLOGY}
53+ AUTH : ${AUTH}
54+ SSL : ${SSL}
55+ ORCHESTRATION_FILE : ${ORCHESTRATION_FILE}
56+ REQUIRE_API_VERSION : ${REQUIRE_API_VERSION}
57+ LOAD_BALANCER : ${LOAD_BALANCER}
58+ COMPRESSOR : ${COMPRESSOR}
59+ # These are paths necessary for launching mongodb
60+ DRIVERS_TOOLS : ${DRIVERS_TOOLS}
61+ MONGODB_BINARIES : ${MONGODB_BINARIES}
62+ args :
63+ - .github/scripts/run-orchestration.sh
64+ name : Encryption tests
65+ env :
66+ FORCE_COLOR : true
67+ steps :
68+ - uses : actions/checkout@d632683dd7b4114ad314bca15554477dd762a938 # v4.2.0
69+ - name : Setup node
70+ uses : actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # v4.0.4
6071 with :
61- release_version : ${{ env.package_version }}
62- product_name : mongodb
63- sarif_report_target_ref : ' main'
64- third_party_dependency_tool : n/a
65- dist_filenames : artifacts/*
66- token : ${{ github.token }}
67- sbom_file_name : sbom.json
68- evergreen_project : mongo-node-driver-next
69- evergreen_commit : ${{ env.commit }}
70-
71- - uses : mongodb-labs/drivers-github-tools/upload-s3-assets@v2
72+ node-version : latest
73+ - name : Load MongoDB binary cache
74+ id : cache-mongodb-binaries
75+ uses : actions/cache@v4
7276 with :
73- version : ${{ env.package_version }}
74- product_name : mongodb
75- dry_run : ${{ needs.release_please.outputs.release_created == '' }}
77+ path : ~/.cache/mongodb-binaries
78+ key : ${{ matrix.os }}-${{ matrix.mongodb }}
79+ - name : Install Dependencies
80+ run : npm install
81+ - name : Install drivers-evergreen-tools
82+
83+ - name : Test
84+ run : mocha --exit ./test/encryption/*.test.js
0 commit comments