This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module FillInWysihtml5Helpers | |
def fill_in_wysihtml5(label, options = {}) | |
page.execute_script <<-JAVASCRIPT | |
var id = $("label:contains(#{label})").attr("for"); | |
$("#" + id).data("wysihtml5").editor.setValue("#{options[:with]}"); | |
JAVASCRIPT | |
end | |
def read_wysihtml5(label) | |
page.execute_script <<-JAVASCRIPT |