PageRenderTime 35ms CodeModel.GetById 12ms RepoModel.GetById 1ms app.codeStats 0ms

/BlogEngine/BlogEngine.Tests/PageTemplates/Account/Login.cs

#
C# | 37 lines | 31 code | 6 blank | 0 comment | 0 complexity | 63f915c81c997da290fd5ddb045a1c5c MD5 | raw file
Possible License(s): LGPL-2.1, Apache-2.0, BSD-3-Clause
  1. using WatiN.Core;
  2. namespace BlogEngine.Tests.PageTemplates.Account
  3. {
  4. public class Login : Page
  5. {
  6. private const string userName = "UserName";
  7. private const string password = "Password";
  8. private const string loginButton = "LoginButton";
  9. private const string loginLinkId = "ctl00_aLogin";
  10. public string Url
  11. {
  12. get { return Constants.Root + "/Account/login.aspx"; }
  13. }
  14. public TextField UserName
  15. {
  16. get { return Document.TextField(Find.ById(userName)); }
  17. }
  18. public TextField Password
  19. {
  20. get { return Document.TextField(Find.ById(password)); }
  21. }
  22. public Button LoginButton
  23. {
  24. get { return Document.Button(Find.ById(loginButton)); }
  25. }
  26. public Link LogoffLink
  27. {
  28. get { return Document.Link(Find.ById(loginLinkId)); }
  29. }
  30. }
  31. }