Skip to content

PHPLIB-866: CSFLE prose test for on-demand AWS credentials #1009

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 29, 2022

Conversation

jmikola
Copy link
Member

@jmikola jmikola commented Nov 29, 2022

@jmikola jmikola requested a review from alcaeus November 29, 2022 03:28
TOPOLOGY: "replica_set"
- func: "start kms servers"
- func: "run tests"
vars:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just improved my understanding of the vars construct by reading through Expansions in the Evergreen docs.

Notice that the function reference can define a set of vars which are treated as expansions within the configuration of the commands in the function.

I reckon my prior confusion was due to our historically inconsistent naming/formatting. I assumed some (like "TESTS") were environment variables, but that's not the case until we explicitly export or declare them when invoking a shell command.

A few more of these PRs and I'll probably want to take on some Evergreen config refactoring.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few more of these PRs and I'll probably want to take on some Evergreen config refactoring.

I'll make a note of it to remember when the next refactoring inevitably comes around...

];

if (! $shouldSucceed) {
$this->expectException(AuthenticationException::class);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is more specific than some other assertions we make in this file, but I inferred it from the corresponding libmongoc test in mongodb/mongo-c-driver@9c4f49f#diff-d363a5539f2fbabfadf2d7cc6cdb96a203fb63f2caa31bae731c3e12d97b204cR5013.

*
* @see https://github.com/mongodb/specifications/tree/master/source/client-side-encryption/tests#on-demand-aws-credentials
* @testWith [true]
* [false]
Copy link
Member Author

@jmikola jmikola Nov 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The $shouldSucceed=false case corresponds to testOnDemandAwsCredentials_with_data_set__1 in this task log.

@jmikola jmikola merged commit 8e8364f into mongodb:master Nov 29, 2022
@jmikola jmikola deleted the phplib-866 branch November 29, 2022 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants