10674: Extend pipeline/workflow creation test to check that parameter with default...
[arvados.git] / apps / workbench / test / diagnostics_test_helper.rb
index 09dc0bb2d4b08332126c6e5524e8cbf14929d082..3587721edae7bc6e96778efceaaedfadddbeacd3 100644 (file)
@@ -6,7 +6,7 @@ require 'yaml'
 # will not be executed.
 
 # Command to run diagnostics tests:
-#   RAILS_ENV=diagnostics bundle exec rake TEST=test/diagnostics/*.rb
+#   RAILS_ENV=diagnostics bundle exec rake TEST=test/diagnostics/**/*.rb
 
 class DiagnosticsTest < ActionDispatch::IntegrationTest
 
@@ -24,14 +24,12 @@ class DiagnosticsTest < ActionDispatch::IntegrationTest
   # Looks for the text_to_look_for for up to the max_time provided
   def wait_until_page_has text_to_look_for, max_time=30
     max_time = 30 if (!max_time || (max_time.to_s != max_time.to_i.to_s))
+    text_found = false
     Timeout.timeout(max_time) do
-      loop until page.has_text?(text_to_look_for)
+      until text_found do
+        visit_page_with_token 'active', current_path
+        text_found = has_text?(text_to_look_for)
+      end
     end
   end
-
-  # Diagnostics tests never want to reset the database fixtures.
-  protected
-  def self.reset_api_fixtures_now
-  end
-
 end