0

I am trying to enter text in redctor text field to test functional testing by geb.But i am not able to do so because textarea is invisible.when it is simple html text field than i am able to do so by personal{$("#personalStatement").value("hi I AM HERE")} but in this case it is not working .I have used in testspec like this also personalStatement ="i am here" but not woking.

<div class="redactor_redactor_content_cv redactor_ui-wizard-content redactor_editor" 

  contenteditable="true" dir="ltr" style="min-height: 200px;"> <p>​</p> </div> <textarea 

   id="personalStatement" class="redactor_content_cv ui-wizard-content" width="98%" 

   height="100px" name="personalStatement" dir="ltr" style="display: none;"> </textarea>

plsgogame
  • 1,334
  • 15
  • 28
user3091180
  • 21
  • 1
  • 7
  • I'd be surprised if it *did* work. Geb (and Selenium) interact with a UI. Here you're effectively trying to emulate the user typing into an invisible field, which can't (shouldn't) be done. I suspect you'd have to use `js.exec` or some clever CSS tricks to display the field stealthily before you could interact with it using Geb. – inanutshellus Jan 09 '14 at 16:17

1 Answers1

0

Use send keys method for entering values in textarea.

$("#personalStatement").firstElement().sendKeys("Test")