Skip to content

Commit

Permalink
ci(NODE-5668): remove custom dep tests against master and fix prose t…
Browse files Browse the repository at this point in the history
…est 14 (#3884)

Co-authored-by: Neal Beeken <neal.beeken@mongodb.com>
  • Loading branch information
baileympearson and nbbeeken committed Oct 6, 2023
1 parent 74833fb commit 2ab2189
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 78 deletions.
54 changes: 0 additions & 54 deletions .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3069,23 +3069,6 @@ tasks:
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: run-custom-csfle-tests-5.0-master
tags:
- run-custom-dependency-tests
commands:
- command: expansions.update
type: setup
params:
updates:
- {key: NODE_LTS_VERSION, value: '14'}
- {key: NPM_VERSION, value: '9'}
- {key: VERSION, value: '5.0'}
- {key: TOPOLOGY, value: replica_set}
- {key: CSFLE_GIT_REF, value: master}
- func: install dependencies
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: run-custom-csfle-tests-rapid-pinned-commit
tags:
- run-custom-dependency-tests
Expand All @@ -3103,23 +3086,6 @@ tasks:
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: run-custom-csfle-tests-rapid-master
tags:
- run-custom-dependency-tests
commands:
- command: expansions.update
type: setup
params:
updates:
- {key: NODE_LTS_VERSION, value: '14'}
- {key: NPM_VERSION, value: '9'}
- {key: VERSION, value: rapid}
- {key: TOPOLOGY, value: replica_set}
- {key: CSFLE_GIT_REF, value: master}
- func: install dependencies
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: run-custom-csfle-tests-latest-pinned-commit
tags:
- run-custom-dependency-tests
Expand All @@ -3137,23 +3103,6 @@ tasks:
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: run-custom-csfle-tests-latest-master
tags:
- run-custom-dependency-tests
commands:
- command: expansions.update
type: setup
params:
updates:
- {key: NODE_LTS_VERSION, value: '14'}
- {key: NPM_VERSION, value: '9'}
- {key: VERSION, value: latest}
- {key: TOPOLOGY, value: replica_set}
- {key: CSFLE_GIT_REF, value: master}
- func: install dependencies
- func: bootstrap mongo-orchestration
- func: bootstrap kms servers
- func: run custom csfle tests
- name: test-latest-server-noauth
tags:
- latest
Expand Down Expand Up @@ -4483,11 +4432,8 @@ buildvariants:
run_on: rhel80-large
tasks:
- run-custom-csfle-tests-5.0-pinned-commit
- run-custom-csfle-tests-5.0-master
- run-custom-csfle-tests-rapid-pinned-commit
- run-custom-csfle-tests-rapid-master
- run-custom-csfle-tests-latest-pinned-commit
- run-custom-csfle-tests-latest-master
- name: rhel8-test-serverless
display_name: Serverless Test
run_on: rhel80-large
Expand Down
38 changes: 17 additions & 21 deletions .evergreen/generate_evergreen_tasks.js
Original file line number Diff line number Diff line change
Expand Up @@ -611,28 +611,24 @@ BUILD_VARIANTS.push({

const oneOffFuncAsTasks = [];

const FLE_PINNED_COMMIT = 'c56c70340093070b1ef5c8a28190187eea21a6e9';

for (const version of ['5.0', 'rapid', 'latest']) {
for (const ref of [FLE_PINNED_COMMIT, 'master']) {
oneOffFuncAsTasks.push({
name: `run-custom-csfle-tests-${version}-${ref === 'master' ? ref : 'pinned-commit'}`,
tags: ['run-custom-dependency-tests'],
commands: [
updateExpansions({
NODE_LTS_VERSION: LOWEST_LTS,
NPM_VERSION: 9,
VERSION: version,
TOPOLOGY: 'replica_set',
CSFLE_GIT_REF: ref
}),
{ func: 'install dependencies' },
{ func: 'bootstrap mongo-orchestration' },
{ func: 'bootstrap kms servers' },
{ func: 'run custom csfle tests' }
]
});
}
oneOffFuncAsTasks.push({
name: `run-custom-csfle-tests-${version}-pinned-commit`,
tags: ['run-custom-dependency-tests'],
commands: [
updateExpansions({
NODE_LTS_VERSION: LOWEST_LTS,
NPM_VERSION: 9,
VERSION: version,
TOPOLOGY: 'replica_set',
CSFLE_GIT_REF: 'c56c70340093070b1ef5c8a28190187eea21a6e9'
}),
{ func: 'install dependencies' },
{ func: 'bootstrap mongo-orchestration' },
{ func: 'bootstrap kms servers' },
{ func: 'run custom csfle tests' }
]
});
}

const coverageTask = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,12 @@ describe('14. Decryption Events', metadata, function () {
keyId: keyId,
algorithm: 'AEAD_AES_256_CBC_HMAC_SHA_512-Deterministic'
});
// Copy ``ciphertext`` into a variable named ``malformedCiphertext``.
// Change the last byte to 0. This will produce an invalid HMAC tag.
// Copy ``ciphertext`` into a variable named ``malformedCiphertext``. Change the
// last byte to a different value. This will produce an invalid HMAC tag.
const buffer = Buffer.from(cipherText.buffer);
buffer.writeInt8(0, buffer.length - 1);
const lastByte = buffer.readUInt8(buffer.length - 1);
const replacementByte = lastByte === 0 ? 1 : 0;
buffer.writeUInt8(replacementByte, buffer.length - 1);
malformedCiphertext = new Binary(buffer, 6);
// Create a MongoClient named ``encryptedClient`` with these ``AutoEncryptionOpts``:
// AutoEncryptionOpts {
Expand Down

0 comments on commit 2ab2189

Please sign in to comment.