Reload your Jasmine suite in Firefox via MozRepl and get success/failure information
Go to file
2018-05-30 06:16:40 -04:00
lib kind of working, yay 2011-02-18 11:33:47 -05:00
.gitignore kind of working, yay 2011-02-18 11:33:47 -05:00
Gemfile kind of working, yay 2011-02-18 11:33:47 -05:00
jasmine-mozrepl.gemspec kind of working, yay 2011-02-18 11:33:47 -05:00
Rakefile kind of working, yay 2011-02-18 11:33:47 -05:00
README.md Update Jasmine link 2018-05-30 00:00:52 -04:00

Reload Jasmine test suites in Firefox using MozRepl and this lovely gem.

Use it with watchr:

require 'jasmine-mozrepl'

extend Jasmine::MozRepl

watch('public/javascript/.*\.js') { do_reload }
watch('spec/javascripts/.*_spec\.js') { do_reload }

def do_reload
  system %{growlnotify -m "#{repl_reload(:echo_to_console => true)}" -t "Jasmine suite"}
end

do_reload

repl_reload options:

  • :host is the host to connect to (default: 127.0.0.1)
  • :port is the post to connect to (default: 4242)
  • :jasmine_matcher is the address in the address bar to search for (default: "localhost:8888")
  • :echo_to_console writes the success/failure message to the console in red/green (default: false)

repl_reload returns the success/failure count message from Jasmine so you can use it as you wish.