0

Help me please! I try to enter to my app (https://testing.shipnext.com/), but modal window don't allow me. I must to enter the logon / password, but i can't do it. I try to use this code:

Alert alert;

@BeforeClass
public static void setup(){
    System.setProperty("webdriver.chrome.driver", "/home/qa-1/IdeaProjects/chromedriver");
    driver = new ChromeDriver();
    loginPage = new LoginPage(driver);
    driver.manage().window().maximize();
    driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
    driver.get("https://testing.shipnext.com/");
}

@Test
public void alertText(){
    alert = driver.switchTo().alert();
    alert.sendKeys("myLogin");
undetected Selenium
  • 183,867
  • 41
  • 278
  • 352
Igor
  • 5
  • 2

1 Answers1

0

Please use below statement with credentials(valid username and password) to launch URL.

driver.get("https://**username**:**password**@testing.shipnext.com/");
Bharadwaj Pendyala
  • 324
  • 1
  • 3
  • 16
  • I can enter to website, but when i try to sign in with my login / psw i have the error: – Igor Oct 25 '18 at 10:28
  • promiseMiddleware.js:59 TypeError: Failed to execute 'fetch' on 'Window': Request cannot be constructed from a URL that includes credentials: /api/v1/auth/sign_in at api.js:103 at tryCatch (runtime.js?1791:63) at Generator._invoke (runtime.js?1791:337) at Generator.prototype.(/anonymous function) [as next] (https://shipnext:atdnsshinc@testing.shipnext.com/assets/vendor.206dd964031ae16f2d90.js:8:30696) at step (asyncToGenerator.js:17) at asyncToGenerator.js:35 at new Promise () at new F (_export.js:35) at a – Igor Oct 25 '18 at 10:29