Advertisement
Guest User

Untitled

a guest
Apr 22nd, 2017
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.05 KB | None | 0 0
  1. <div class="loader-mask" data-bind="visible: false">
  2. <div class="loader"> Loading Form...</div>
  3. </div>
  4. <div class="form-group">
  5. <label class="control-label">Email ID:</label>
  6. <input type="text" name="username" class="form-control" placeholder="user@company.com" data-bind="
  7. value: loginHandler.userEmail,
  8. enterKey: signIn
  9. ">
  10. </div><!-- /.form-group -->
  11. <div class="form-group">
  12. <label class="control-label">Password:</label>
  13. <input type="password" name="password" class="form-control" placeholder="Passwords are case-sensitive" data-bind="
  14. value: loginHandler.userPassword,
  15. enterKey: signIn
  16. ">
  17. </div><!-- /.form-group -->
  18. <div class="text-right">
  19. <p><button type="button" id="qaSignIn" class="btn btn-default" data-bind="
  20. click: signIn,
  21. disable: loginHandler.isLoggingIn,
  22. continueOn: userLoggedIn,
  23. continueLink: { link: 'dashboard.html', params: {} }
  24. ">
  25.  
  26. HtmlTextInput htmlInputUsername = (HtmlTextInput) loginPage.getElementByName("username");
  27. htmlInputUsername.setValueAttribute("myUserName");
  28. HtmlPasswordInput htmlInputPassword = (HtmlPasswordInput) loginPage.getElementByName("password");
  29. htmlInputPassword.setValueAttribute("myPassword");
  30. HtmlButton htmlButton = (HtmlButton) loginPage.getElementById("qaSignIn");
  31. loginPage = htmlButton.click();
  32.  
  33. webClient.getOptions().setUseInsecureSSL(true);
  34. webClient.getCookieManager().setCookiesEnabled(true);
  35. webClient.getOptions().setJavaScriptEnabled(false);
  36. webClient.getOptions().setCssEnabled(true);
  37. webClient.getOptions().setRedirectEnabled(true);
  38. webClient.setAjaxController(new NicelyResynchronizingAjaxController());
  39. webClient.waitForBackgroundJavaScript(30000);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement