-
Notifications
You must be signed in to change notification settings - Fork 54
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
OIDC e2e tests #645
base: main
Are you sure you want to change the base?
OIDC e2e tests #645
Conversation
- wdio-vscode-service | ||
- wdio-wait-for | ||
- "@wdio/globals" | ||
- "@wdio/types" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In Compass and mongosh our depcheckrcs often have comments about why a specific dependency is in the ignore list, this might be an opportunity to also introduce this pattern here 🙂
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense - I will make sure to do that.
src/test/e2e/oidc.e2e.ts
Outdated
|
||
before(async function () { | ||
if (process.platform !== 'linux') { | ||
// return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
^
just so we don't forget
async () => { | ||
const notifs = await workbench.getNotifications(); | ||
const messages = await Promise.all(notifs.map((n) => n.getMessage())); | ||
return messages.includes('MongoDB connection successful.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there some easy way of verifying that we connected as an authenticated user (and in particular that the connection attempt did not accidentally succeed because it is fully unauthenticated and makes use of the MongoDB localhost exception)?
In Compass and mongosh we use connectionStatus
and/or check that the OIDC IDP has actually issued a token by looking at the contents of oidcMockProviderEndpointAccesses
, those might be good things to try here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yea in addition to what is suggested I also wanted to include the authInfo check which unfortunately due to limitations being posed right now, I am unable to. Will be looking into this today but thank you for this ⭐
Draft version
Description
Checklist
Motivation and Context
Open Questions
Dependents
Types of changes