DEV: Retry when Net::HTTP throws EOFError (#10921)

DEV: Retry when Net::HTTP throws EOFError (#10921)

Might fix an inconsistent issue when running tests in CI.

diff --git a/lib/tasks/qunit.rake b/lib/tasks/qunit.rake
index cb27a6c..235a317 100644
--- a/lib/tasks/qunit.rake
+++ b/lib/tasks/qunit.rake
@@ -86,7 +86,7 @@ task "qunit:test", [:timeout, :qunit_path] do |_, args|
     puts "Warming up Rails server"
     begin
       Net::HTTP.get(uri)
-    rescue Errno::ECONNREFUSED, Errno::EADDRNOTAVAIL, Net::ReadTimeout
+    rescue Errno::ECONNREFUSED, Errno::EADDRNOTAVAIL, Net::ReadTimeout, EOFError
       sleep 1
       retry unless elapsed() > 60
       puts "Timed out. Can not connect to forked server!"

GitHub sha: caa58a4b

This commit appears in #10921 which was approved by Supermathie. It was merged by pmusaraj.