-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implements API key authentication for serverless API integration tests (
#178558) Closes #177022 ## Summary This PR introduces two new functions to the user manager serverless test service to facilitate authentication via API keys for API integration tests: - createApiKeyForRole: gets a session cookie for a specific role (by name) and uses it to generate an API key for that role. - invalidateApiKeyForRole: invalidates the API key generated in createApiKeyForRole, given a valid cookie and API key. As an example/reference, I have updated the common management spaces API integration tests to remove basic authentication, and use API key authentication instead. See: `x-pack/test_serverless/api_integration/test_suites/common/management/spaces.ts` cc: @pheyos & @dmlemeshko
- Loading branch information
1 parent
8364ce8
commit 7975fab
Showing
3 changed files
with
108 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters