Skip to content

Commit

Permalink
Ruby selenium-webdriver needs you to specify a json library. Adding i…
Browse files Browse the repository at this point in the history
…t to Ruby formatters for Selenium IDE
  • Loading branch information
samitbadle committed Aug 11, 2013
1 parent 7b5d5b2 commit 7bde5ab
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
7 changes: 3 additions & 4 deletions ide/plugins/ruby-format/src/content/formats/ruby-wd-rspec.js
Original file line number Diff line number Diff line change
Expand Up @@ -308,8 +308,8 @@ function defaultExtension() {
this.options = {
receiver: "@driver",
showSelenese: 'false',
header:
'require "selenium-webdriver"\n' +
header: 'require "json"\n' +
'require "selenium-webdriver"\n' +
'require "rspec"\n' +
'include RSpec::Expectations\n' +
'\n' +
Expand All @@ -329,8 +329,7 @@ this.options = {
' end\n' +
' \n' +
' it "${methodName}" do\n',
footer:
" end\n" +
footer: " end\n" +
" \n" +
" def element_present?(how, what)\n" +
" @driver.find_element(how, what)\n" +
Expand Down
7 changes: 3 additions & 4 deletions ide/plugins/ruby-format/src/content/formats/ruby-wd.js
Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,8 @@ function defaultExtension() {
this.options = {
receiver: "@driver",
showSelenese: 'false',
header:
'require "selenium-webdriver"\n' +
header: 'require "json"\n' +
'require "selenium-webdriver"\n' +
'gem "test-unit"\n' +
'require "test/unit"\n' +
'\n' +
Expand All @@ -312,8 +312,7 @@ this.options = {
' end\n' +
' \n' +
' def ${methodName}\n',
footer:
" end\n" +
footer: " end\n" +
" \n" +
" def element_present?(how, what)\n" +
" @driver.find_element(how, what)\n" +
Expand Down

0 comments on commit 7bde5ab

Please sign in to comment.