Permalink
Browse files

CI: retry failed tests

It's an unfortunate reality that PhantomJS does crash from time to time,
and when you have over 500 tests running on 6 different rubies there is
a high chance that at least on of those runs will fail. So hopefully
this will help mitigate that.
  • Loading branch information...
1 parent 6769b80 commit 40f63482c4d32dd1f5af2e567556eac91aa327f0 @jonleighton jonleighton committed Oct 7, 2012
Showing with 6 additions and 0 deletions.
  1. +1 −0 .gitignore
  2. +1 −0 .rspec
  3. +1 −0 .travis.yml
  4. +2 −0 Rakefile
  5. +1 −0 poltergeist.gemspec
View
@@ -2,3 +2,4 @@
/spec/support/custom_phantomjs_called
/ci/Gemfile.*.lock
/spec/tmp
+/rspec.failures
View
@@ -0,0 +1 @@
+--format progress
View
@@ -5,6 +5,7 @@ before_script:
- sudo ci/install_phantomjs
- "export PATH=phantomjs/bin:$PATH"
- phantomjs --version
+script: rake ci
rvm:
- 1.9.3
- 1.9.2
View
@@ -4,6 +4,7 @@ require 'rspec/core/rake_task'
base = File.dirname(__FILE__)
require base + "/lib/capybara/poltergeist/version"
require 'coffee-script'
+require 'rspec-rerun'
task :autocompile do
system "guard"
@@ -22,6 +23,7 @@ end
RSpec::Core::RakeTask.new('test')
task :default => [:compile, :test]
+task :ci => 'rspec-rerun:spec'
task :release do
puts "Releasing #{Capybara::Poltergeist::VERSION}, y/n?"
View
@@ -26,6 +26,7 @@ Gem::Specification.new do |s|
s.add_development_dependency 'image_size', '~> 1.0'
s.add_development_dependency 'coffee-script', '~> 2.2.0'
s.add_development_dependency 'guard-coffeescript', '~> 1.0.0'
+ s.add_development_dependency 'rspec-rerun', '~> 0.1'
s.files = Dir.glob("{lib}/**/*") + %w(LICENSE README.md)
s.require_path = 'lib'

1 comment on commit 40f6348

@orendon
orendon commented on 40f6348 Jun 6, 2014

:trollface:

Please sign in to comment.