5694: remove the extra white space in log tab display.
authorradhika <radhika@curoverse.com>
Thu, 25 Feb 2016 02:52:23 +0000 (21:52 -0500)
committerradhika <radhika@curoverse.com>
Thu, 25 Feb 2016 02:52:23 +0000 (21:52 -0500)
apps/workbench/app/views/jobs/_show_log.html.erb
apps/workbench/config/application.default.yml
apps/workbench/test/integration/websockets_test.rb

index 68a07efa28576afaa1255729c01e0b0ba49cd572..02ad2b73986856185e6b66bbaacd6d8a1a5826c7 100644 (file)
@@ -7,8 +7,8 @@
 
 <div id="event_log_div"
      class="arv-log-event-listener arv-log-event-handler-append-logs arv-job-log-window"
-     data-object-uuid="<%= @object.uuid %>" >
-  <%= @object.stderr_log_lines(Rails.configuration.running_job_log_lines_to_fetch).join("\n") %>
+     data-object-uuid="<%= @object.uuid %>"
+  ><%= @object.stderr_log_lines(Rails.configuration.running_job_log_records_to_fetch).join("\n") %>
 </div>
 
 <%# Applying a long throttle suppresses the auto-refresh of this
index ab0deff2f9f4023ab435da647f711bc85c9497de..5400debbfdaf55e1f64c004adf70f98ca4037cb1 100644 (file)
@@ -273,6 +273,6 @@ common:
   # The default setting (false) is appropriate for a multi-user site.
   trust_all_content: false
 
-  # Maximum number of historic log lines of a running job to fetch
+  # Maximum number of historic log records of a running job to fetch
   # and display in the Log tab, while subscribing to web sockets.
-  running_job_log_lines_to_fetch: 2000
+  running_job_log_records_to_fetch: 2000
index a2300b7b636df6cec6d55bcec572fa14f244ff7e..655ad92c94d1d18f23988990c59cb832a817fb9e 100644 (file)
@@ -212,14 +212,14 @@ class WebsocketTest < ActionDispatch::IntegrationTest
     assert_in_epsilon value, datum.to_f
   end
 
-  test "test running job with just a few previous log lines" do
+  test "test running job with just a few previous log records" do
     Thread.current[:arvados_api_token] = @@API_AUTHS["admin"]['api_token']
     job = Job.where(uuid: api_fixture("jobs")['running']['uuid']).results.first
     visit page_with_token("admin", "/jobs/#{job.uuid}")
 
     api = ArvadosApiClient.new
 
-    # Create just one old log line
+    # Create just one old log record
     api.api("logs", "", {log: {
                 object_uuid: job.uuid,
                 event_type: "stderr",
@@ -227,11 +227,11 @@ class WebsocketTest < ActionDispatch::IntegrationTest
 
     click_link("Log")
 
-    # Expect "all" historic log lines because we have less than
-    # default Rails.configuration.running_job_log_lines_to_fetch count
+    # Expect "all" historic log records because we have less than
+    # default Rails.configuration.running_job_log_records_to_fetch count
     assert_text 'Historic log message'
 
-    # Create new log line and expect it to show up in log tab
+    # Create new log record and expect it to show up in log tab
     api.api("logs", "", {log: {
                 object_uuid: job.uuid,
                 event_type: "stderr",
@@ -239,8 +239,8 @@ class WebsocketTest < ActionDispatch::IntegrationTest
     assert_text 'Log message after subscription'
   end
 
-  test "test running job with too many previous log lines" do
-    Rails.configuration.running_job_log_lines_to_fetch = 5
+  test "test running job with too many previous log records" do
+    Rails.configuration.running_job_log_records_to_fetch = 5
 
     Thread.current[:arvados_api_token] = @@API_AUTHS["admin"]['api_token']
     job = Job.where(uuid: api_fixture("jobs")['running']['uuid']).results.first
@@ -249,8 +249,8 @@ class WebsocketTest < ActionDispatch::IntegrationTest
 
     api = ArvadosApiClient.new
 
-    # Create Rails.configuration.running_job_log_lines_to_fetch + 1 log lines
-    (0..Rails.configuration.running_job_log_lines_to_fetch).each do |count|
+    # Create Rails.configuration.running_job_log_records_to_fetch + 1 log records
+    (0..Rails.configuration.running_job_log_records_to_fetch).each do |count|
       api.api("logs", "", {log: {
                 object_uuid: job.uuid,
                 event_type: "stderr",
@@ -260,14 +260,14 @@ class WebsocketTest < ActionDispatch::IntegrationTest
     # Go to log tab, which results in subscribing to websockets
     click_link("Log")
 
-    # Expect all but the first historic log lines,
+    # Expect all but the first historic log records,
     # because that was one too many than fetch count.
-    (1..Rails.configuration.running_job_log_lines_to_fetch).each do |count|
+    (1..Rails.configuration.running_job_log_records_to_fetch).each do |count|
       assert_text "Old log message #{count}"
     end
     assert_no_text 'Old log message 0'
 
-    # Create one more log line after subsription
+    # Create one more log record after subscription
     api.api("logs", "", {log: {
                 object_uuid: job.uuid,
                 event_type: "stderr",