Skip to content
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

Execute web Test on a particular selenium 4 grid nodes #2923

Open
remyanekkuth opened this issue Sep 14, 2022 · 6 comments
Open

Execute web Test on a particular selenium 4 grid nodes #2923

remyanekkuth opened this issue Sep 14, 2022 · 6 comments

Comments

@remyanekkuth
Copy link

Hi @wakaleo

Recently we migrated to selenium 4 and would like to have a capability to run test on a particular node.
eg : we have environment integration where we have 5 nodes registered and available in console. I would like to run test on a particular node (eg : node A) rather than picking random.

Right now our run configuration looks like this :
-Denvironment=integ -Dwebdriver.driver=remote -Dwebdriver.remote.driver=edge

How to pass the node id through the run configuration ?

@wakaleo
Copy link
Member

wakaleo commented Sep 14, 2022

How would you do this in plain Selenium?

@remyanekkuth
Copy link
Author

@wakaleo Right now we are not doing this even with selenium 3.
we tried to pass some capabilities from properties and run, but it didn’t work well that time with custom driver capabilities.

Appreciate suggestions on how can I hit particular node through configuration.

@globalworming
Copy link
Collaborator

that's not how you use the grid, right? you let the hub decide which node to pick.
though this answer suggests you can pick the node by setting the remote url

@globalworming
Copy link
Collaborator

a similar question is unanswered

@wakaleo
Copy link
Member

wakaleo commented Sep 14, 2022

All the W3C and driver-specific capabilities go in the capabilities section (https://serenity-bdd.github.io/docs/guide/driver_config#specifying-w3c-properties) where they are passed as-is. However if you need to provide a custom remote URL that is different each time, you could try implementing the ProvidesRemoteWebdriverUrl interface.

@remyanekkuth
Copy link
Author

@wakaleo if there is any example you can point out about implementing ProvidesRemoteWebdriverUrl

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

No branches or pull requests

3 participants