* add a class for checking pod connectivity * extend pod model to handle new functionality * add an admin frontend to list pods and re-trigger checks manually * add a daily worker to run through all the pods * add unit tests for most of the new code
17 lines
382 B
Ruby
17 lines
382 B
Ruby
|
|
require "spec_helper"
|
|
|
|
describe Workers::RecurringPodCheck do
|
|
before do
|
|
@pods = (0..4).map do
|
|
FactoryGirl.create(:pod).tap { |pod|
|
|
expect(pod).to receive(:test_connection!)
|
|
}
|
|
end
|
|
allow(Pod).to receive(:find_in_batches) { @pods }
|
|
end
|
|
|
|
it "performs a connection test on all existing pods" do
|
|
Workers::RecurringPodCheck.new.perform
|
|
end
|
|
end
|