Skip to content

Commit

Permalink
make backburner integration test to work
Browse files Browse the repository at this point in the history
Currently, backburner integration test is not running on CI.
https://travis-ci.org/rails/rails/jobs/196005322#L610

Using `Backburner::Worker.connection` to check whether beanstalkd is
running. But `Backburner::Worker.connection` was removed in backburner
1.2.0.
nesquena/backburner@81fde49

Therefore, this check process always becomes false, so the test is no
longer done. I fixed it so that check processing is done correctly.
  • Loading branch information
y-yagi committed Jan 28, 2017
1 parent 05112b2 commit acd4840
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions activejob/test/support/integration/adapters/backburner.rb
Expand Up @@ -23,12 +23,12 @@ def stop_workers
end

def tube
@tube ||= Beaneater::Tube.new(Backburner::Worker.connection, "backburner.worker.queue.integration-tests") # backburner dasherizes the queue name
@tube ||= Beaneater::Tube.new(@worker.connection, "backburner.worker.queue.integration-tests") # backburner dasherizes the queue name
end

def can_run?
begin
Backburner::Worker.connection.send :connect!
@worker = Backburner::Worker.new
rescue
return false
end
Expand Down

0 comments on commit acd4840

Please sign in to comment.