/BlogEngine/BlogEngine.Tests/PageTemplates/Admin/EditPost.cs
C# | 28 lines | 23 code | 4 blank | 1 comment | 0 complexity | 751ebab168dc3b6a8fa7bc45f312a8d5 MD5 | raw file
Possible License(s): LGPL-2.1, Apache-2.0, BSD-3-Clause
- using WatiN.Core;
-
- namespace BlogEngine.Tests.PageTemplates.Admin
- {
- public class EditPost : Page
- {
- public string Url
- {
- get { return Constants.Root + "/admin/Posts/Add_entry.aspx"; }
- }
-
- public TextField PostTitle
- {
- get { return Document.TextField(Find.ById("ctl00_cphAdmin_txtTitle")); }
- }
-
- // tinyMCE uses frames to simulate text area, need javascript hack as workaround
- public string JsHack
- {
- get { return "document.getElementById('ctl00_cphAdmin_txtContent_TinyMCE1_txtContent_ifr').contentWindow.document.body.innerHTML = 'This is WATIN test post.';"; }
- }
-
- public Button Save
- {
- get { return Document.Button(Find.ById("btnSave")); }
- }
- }
- }