Ask a Question

Basic Authentication with Cross-browser tests

SOLVED
simonaferrara
Contributor

Basic Authentication with Cross-browser tests

Hi all,

 

I'm implementing some cross-browser tests by using Test Complete integrated with Selenium Grid.

The site has got basic authentication, so the login form appears when opening the remote web page.

 

Without cross-browser tests I had no issues, by using the Login object supplied by Test Complete, but now I'm encountering the fact that the Login object is not supported for cross-browser tests.

 

As suggested by the documentation ( https://support.smartbear.com/testcomplete/docs/app-testing/web/common-tasks/popups-and-dialogs.html... ) I've tried to send the required credentials as part of the target web page URL, but unfortunately the site is security-protected for this type of url and it returns me the "Request cannot be constructed from a URL that includes credentials" error.

 

I've searched and tried other solutions from the Selenium point of view, but I've not found anything that solve the issue till now or I had been not able to apply some suggested code found on the web.

 

Do you have any suggestion of an alternative to be applied to interact with the login form for cross-platform tests?

 

Thanks and regards,

Simona

1 ACCEPTED SOLUTION

Accepted Solutions
AlexKaras
Community Hero

Re: Basic Authentication with Cross-browser tests

Hi,

 

Selenium by design cannot handle any system-provided window / dialog, including the login one.

https://www.linkedin.com/pulse/how-setup-selenium-grid-browsermob-proxy-pass-basic-solution-gamage might inspire you with some ideas (if you haven't already tried suggested or similar approaches).

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

1 REPLY 1
AlexKaras
Community Hero

Re: Basic Authentication with Cross-browser tests

Hi,

 

Selenium by design cannot handle any system-provided window / dialog, including the login one.

https://www.linkedin.com/pulse/how-setup-selenium-grid-browsermob-proxy-pass-basic-solution-gamage might inspire you with some ideas (if you haven't already tried suggested or similar approaches).

 

Regards,
  /Alex [Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
================================

View solution in original post

cancel
Showing results for 
Search instead for 
Did you mean: