-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
feat(tests): Grid, FF and iframeAPI tests. #15372
Conversation
The context is being created on every new suite in before hook.
Drop URL params.
Certain tests are disable as not supported on FF. Missing upload file function for iframeAPI helper. Missing option to set audio file as a mic source.
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.
🔍 This pull request has been sent to HackerOne's PullRequest review team because our automation detected one or more changes with potential security impact or requires further evaluation. Experts are now being assigned to this review based on relevant expertise and will validate or dismiss any security findings accordingly and post their feedback as comments within this pull request.
Check the status or cancel this secure code review here.
8126574
to
d639ee5
Compare
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.
✅ Jacques reviewed all the included code changes and associated automation findings and determined that there were no immediately actionable security flaws. Note that they will continue to be notified of any new commits or comments and follow up as needed throughout the duration of this pull request's lifecycle.
d639ee5
to
f59cdb9
Compare
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.
Some small comments. Impressive work!
await this.driver.url(url); | ||
// workaround for https://github.com/webdriverio/webdriverio/issues/13956 | ||
if (url.startsWith('file://')) { | ||
// eslint-disable-next-line @typescript-eslint/no-empty-function |
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.
Why not let it throw if there is an exception?
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.
It fails the test because it comes with a timeout. But the problem is fixed and will be available on the next release. I will update it once it is out.
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.
👍
tests/helpers/participants.ts
Outdated
await p.switchInPage(); | ||
|
||
if (await p.isInMuc()) { | ||
return Promise.resolve(); |
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 return, this is an async function.
tests/helpers/participants.ts
Outdated
* Parse a JID string. | ||
* @param str the string to parse. | ||
*/ | ||
export function parseJid(str: string): { |
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.
There was a Strophe helper to do this, wasn't there? Do we want to use it?
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.
Yeah, I was thinking the same ... but was wondering about the dependencies ... but the change will be only in dev dependencies ... I will give it a shot.
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.
Ah good point. Never mind, keep it as is.
async addEventListener(eventName: string) { | ||
return this.participant.driver.executeAsync((event, prefix, done) => { | ||
console.log(`${new Date().toISOString()} ${prefix} Adding listener for event: ${event}`); | ||
window.jitsiAPI.addListener(event, evt => { |
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.
what's with the date?
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.
To make the logs look the same way as the js client logs.
2024-12-09T23:08:07.278Z [modules/UI/videolayout/LargeVideoManager.js] scheduleLargeVideoUpdate: Remote track RemoteTrack[userID: 23f85c98, type: video, ssrc: 2134074178, p2p: false, sourceName: 23f85c98-v0, status: {readyState: live, muted: false, enabled: true}], isVideoMuted=false, streamingStatusActive=true, isVideoRenderable=true, showAvatar=false
2024-12-09T23:08:09.659Z [MeetTest] Adding listener for event: participantRoleChanged
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.
Ah gotcha!
</head> | ||
<body> | ||
<script> | ||
const blacklist = [ '__proto__', 'constructor', 'prototype' ]; |
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.
This is copied from somewhere, right? Maybe put a comment about where it comes from?
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.
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.
To put in comments that it comes from jitsi-meet-torture?
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.
Yes please.
// wdio.dev.conf.ts | ||
// extends te main configuration file for the development environment (make dev) | ||
// it will connect to the webpack-dev-server running locally on port 8080 | ||
import { deepmerge } from 'deepmerge-ts'; |
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.
I assume we somehow already have this dependency? It's not listed as a direct dependency, which it probably should. Or, use lodash's merge?
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.
ok, I will give it a shot. This was copied from webdriverio site.
https://webdriver.io/docs/organizingsuites#inherit-from-main-config-file
tests/helpers/participants.ts
Outdated
* Parse a JID string. | ||
* @param str the string to parse. | ||
*/ | ||
export function parseJid(str: string): { |
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.
I think you did well not introducing the extra dependency, sorry for the noise. I'd undo this.
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.
🔥
No description provided.