Created
September 29, 2010 22:25
-
-
Save hannahwhy/603680 to your computer and use it in GitHub Desktop.
jasmine:ci in Xvfb
This file contains hidden or 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
| $ rake ci:setup:rspec ci:javascripts | |
| (extraneous setup messages elided) | |
| Waiting for jasmine server on 64969... | |
| [2010-10-04 14:37:22] INFO WEBrick 1.3.1 | |
| [2010-10-04 14:37:22] INFO ruby 1.8.7 (2010-08-16) [i686-darwin9.8.0] | |
| [2010-10-04 14:37:22] INFO WEBrick::HTTPServer#start: pid=42331 port=64969 | |
| Waiting for jasmine server on 64969... | |
| jasmine server started. | |
| Running: java -jar "/Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/selenium-rc-2.2.4/vendor/selenium-server.jar" -port 64977 > /dev/null | |
| ==> Waiting for Selenium RC server on port 64977... Ready! | |
| Waiting for suite to finish in browser ... | |
| .......................................................................................................................................................................................................................................................................................Expected 'http://www.example.com/foo' to equal 'http://www.example.com/foos'. | |
| Error("Expected 'http://www.example.com/foo' to equal 'http://www.example.com/foos'.") | |
| (Jasmine backtrace elided) | |
| F........................ | |
| 1) | |
| RuntimeError in 'URL object can substitute arguments for colon-delimited parameters' | |
| Expected 'http://www.example.com/foo' to equal 'http://www.example.com/foos'. | |
| /Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/jasmine-1.0.0/lib/jasmine/spec_builder.rb:142:in `report_spec' | |
| /Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/jasmine-1.0.0/lib/jasmine/spec_builder.rb:113:in `declare_spec' | |
| Finished in 1.033512 seconds | |
| 304 examples, 1 failure | |
| rake aborted! | |
| Command /Users/davidyip/.rvm/rubies/ruby-1.8.7-p302/bin/ruby -I"lib" "/Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/rspec-1.3.0/bin/spec" "spec/javascripts/support/jasmine_runner.rb" --require /Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/ci_reporter-1.6.2/lib/ci/reporter/rake/rspec_loader.rb --format CI::Reporter::RSpec failed | |
| (See full trace by running task with --trace) |
This file contains hidden or 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
| # For the task that I'm actually using, see revision 7b7553. | |
| # This revision is a little more elegant, but I haven't actually run it. | |
| namespace :ci do | |
| task :javascripts do | |
| display = ':1' | |
| server_pid = fork { exec("Xvfb #{display}") } | |
| ENV['DISPLAY'] = display | |
| begin | |
| Rake::Task['jasmine:ci'].invoke | |
| ensure | |
| Process.kill('TERM', server_pid) | |
| Process.waitall | |
| end | |
| end | |
| end |
This file contains hidden or 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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <testsuite failures="0" tests="6" errors="1" skipped="0" name="URL object" time="0.003172"> | |
| <testcase name="can substitute arguments for colon-delimited parameters" time="0.002229"> | |
| <failure type="RuntimeError" message="Expected 'http://www.example.com/foo' to equal 'http://www.example.com/foos'...."> | |
| Expected 'http://www.example.com/foo' to equal 'http://www.example.com/foos'. | |
| (RuntimeError) | |
| /Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/jasmine-1.0.0/lib/jasmine/spec_builder.rb:142:in `report_spec' | |
| /Users/davidyip/.rvm/gems/ruby-1.8.7-p302@pathcore/gems/jasmine-1.0.0/lib/jasmine/spec_builder.rb:113:in `declare_spec' </failure> | |
| </testcase> | |
| <testcase name="can append to the query string" time="9.6e-05"> | |
| </testcase> | |
| <testcase name="can instantiate many different URLs from the sample template" time="8.6e-05"> | |
| </testcase> | |
| <testcase name="does not append a ? if one already exists" time="0.000116"> | |
| </testcase> | |
| <testcase name="extracts the parameters from a url" time="9.3e-05"> | |
| </testcase> | |
| <testcase name="it returns an empty array when no parameters exist" time="8.7e-05"> | |
| </testcase> | |
| <system-out> | |
| </system-out> | |
| <system-err> | |
| </system-err> | |
| </testsuite> |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes. Jasmine's CI runner maps RSpec examples and example groups to Jasmine examples and example groups, respectively, so tools like ci-reporter can capture and report on that data.
I've attached example output of failures.