[ARVADOS] updated: f9ec9073f2077d81567922d612d79e8bcf3a11ba

git at public.curoverse.com git at public.curoverse.com
Fri Sep 26 15:31:21 EDT 2014


Summary of changes:
 .../app/helpers/pipeline_instances_helper.rb       | 27 ++++++--
 apps/workbench/app/models/job.rb                   | 20 ------
 .../views/application/_job_status_label.html.erb   |  3 +-
 .../workbench/app/views/jobs/_show_recent.html.erb |  2 +-
 apps/workbench/app/views/jobs/show.html.erb        |  2 +-
 .../pipeline_instances/_running_component.html.erb |  6 +-
 .../app/views/projects/_show_dashboard.html.erb    |  8 +--
 apps/workbench/app/views/users/_tables.html.erb    |  2 +-
 docker/api/Dockerfile                              |  3 +-
 docker/api/application.yml.in                      |  2 +
 docker/build_tools/build.rb                        |  1 +
 docker/config.yml.example                          |  5 ++
 docker/passenger/Dockerfile                        |  6 +-
 sdk/cli/bin/arv-run-pipeline-instance              | 71 ++++++++-----------
 sdk/cli/bin/crunch-job                             | 38 +++++++----
 .../app/controllers/arvados/v1/jobs_controller.rb  |  7 +-
 services/api/app/controllers/static_controller.rb  | 17 +++--
 services/api/app/mailers/admin_notifier.rb         | 12 ----
 services/api/app/mailers/user_notifier.rb          | 12 ----
 services/api/app/models/job.rb                     |  4 +-
 .../admin_notifier/new_inactive_user.text.erb      |  4 +-
 .../api/app/views/admin_notifier/new_user.text.erb |  4 +-
 .../views/user_notifier/account_is_setup.text.erb  |  4 +-
 services/api/config/application.default.yml        | 18 ++---
 services/api/config/application.yml.example        |  2 +
 services/api/lib/has_uuid.rb                       |  2 +-
 services/api/script/crunch-dispatch.rb             | 79 ++++++++++++++--------
 services/api/test/fixtures/jobs.yml                | 36 +++-------
 .../functional/arvados/v1/jobs_controller_test.rb  | 30 ++++----
 .../functional/arvados/v1/users_controller_test.rb |  8 ++-
 services/api/test/integration/groups_test.rb       |  2 +-
 31 files changed, 212 insertions(+), 225 deletions(-)

       via  f9ec9073f2077d81567922d612d79e8bcf3a11ba (commit)
       via  c360335c441219f20eb6c598870a6a727edc88b4 (commit)
       via  195b23ed7fd0c6261d0a945a9f0e541d78a0648e (commit)
       via  b506247f4a34e1a409f57c3a01c07a94970fe68f (commit)
       via  1b189a0961ba757caf6160285b59daa26c7cdcae (commit)
       via  d4724463bd248922dc37b43f59d54890d10581c1 (commit)
       via  eaf8fb3be8218971b9a66d10b7bbabbbf92cd041 (commit)
       via  c2c38069d28fc68dea6e1b2cb0d5f4f36e1ef03f (commit)
       via  d592a37f987ed90e017bc9d2d962a2f620e27095 (commit)
       via  22c3f131e929bef5574ef71a98bc48290c36dfb3 (commit)
       via  a3787ef83a0538097fb6f802f675be740a241ebc (commit)
       via  ce410ef35e137e040ace097a74a33f04c5975ad9 (commit)
       via  c491bfd795b7c7c4f26f18003290bd7ec9e88d60 (commit)
       via  abc1db31bae1b33ed899a1da4b59f2edc0f5f189 (commit)
       via  1d8f975be8d35444aca0f21a0b6c91bc4a277662 (commit)
       via  4e8745c2a744a2c3e6b44ee6100fb1a26749cebf (commit)
       via  a805395a2a64aa83a1604ade6932151a0846b577 (commit)
       via  48d04722a5e0478e22be33f58036806a55b3a0eb (commit)
       via  1d135e43d06148b100fbc8534144b405e4824af9 (commit)
       via  2861857a87d4c40924f783862ee09e91cec0b96f (commit)
       via  94b11dfc98ed84d0f91f2bc2fc81e76b4d3c35d7 (commit)
       via  e9622f371ad4d75f0a0b5ee9480fae779dd63156 (commit)
       via  5253b7d81a54c6087b35148499c360c692fac870 (commit)
       via  a452ab111d29f4f06d31c3fe760bb17b211020a6 (commit)
       via  9daebff7dfeaa7092da078f3a0bfdc0c9d8e51e0 (commit)
       via  9a15397a7e030704f63441d6e7893cb3d8be1d64 (commit)
       via  3d84dd62a85647e9b3dfc34af8303c09b9923498 (commit)
       via  93c7127afd21f82662e9b471e7c617ae8c59ad19 (commit)
       via  68dc1fcaec00d7d954be19f2c184e04626639616 (commit)
       via  4c53b3aee935b41e11c71ff1468a10d6a80c390c (commit)
       via  c8ad3a2a0f27964eff5d5c2d845afab728836473 (commit)
      from  ebdbddd3c85ab869afcf689efd7cb4b6207000b3 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit f9ec9073f2077d81567922d612d79e8bcf3a11ba
Author: radhika <radhika at curoverse.com>
Date:   Fri Sep 26 15:30:33 2014 -0400

    3889: minor test assertion updates

diff --git a/services/api/test/functional/arvados/v1/users_controller_test.rb b/services/api/test/functional/arvados/v1/users_controller_test.rb
index 745a8e8..1cfb63e 100644
--- a/services/api/test/functional/arvados/v1/users_controller_test.rb
+++ b/services/api/test/functional/arvados/v1/users_controller_test.rb
@@ -34,18 +34,20 @@ class Arvados::V1::UsersControllerTest < ActionController::TestCase
                                 name: 'click',
                                 tail_uuid: users(:inactive).uuid,
                                 head_uuid: required_uuids).
-        collect(&:head_uuid)
+                          collect(&:head_uuid)
 
       assert_equal 0, signed_uuids.length
     end
 
     authorize_with :inactive
+    assert_equal false, users(:inactive).is_active
 
     post :activate, id: users(:inactive).uuid
     assert_response 403
 
-    response_body = JSON.parse(@response.body)
-    assert response_body['errors'].first.include? 'Cannot activate without user agreements'
+    resp = json_response
+    assert resp['errors'].first.include? 'Cannot activate without user agreements'
+    assert_nil resp['is_active']
   end
 
   test "activate an already-active user" do
diff --git a/services/api/test/integration/groups_test.rb b/services/api/test/integration/groups_test.rb
index c144a0f..0f6f93a 100644
--- a/services/api/test/integration/groups_test.rb
+++ b/services/api/test/integration/groups_test.rb
@@ -1,6 +1,6 @@
 require 'test_helper'
 
-class GroupTest < ActionDispatch::IntegrationTest
+class GroupsTest < ActionDispatch::IntegrationTest
 
   test "get all pages of group-owned objects" do
     limit = 5

commit c360335c441219f20eb6c598870a6a727edc88b4
Author: radhika <radhika at curoverse.com>
Date:   Fri Sep 26 14:44:53 2014 -0400

    3889: remove the job fixture "job_with_unnormalized_output_and_log" and instead use "foobar"

diff --git a/services/api/test/fixtures/jobs.yml b/services/api/test/fixtures/jobs.yml
index fee4379..b84922d 100644
--- a/services/api/test/fixtures/jobs.yml
+++ b/services/api/test/fixtures/jobs.yml
@@ -223,28 +223,3 @@ queued:
   tasks_summary: {}
   runtime_constraints: {}
   state: Queued
-
-job_with_unnormalized_output_and_log:
-  uuid: zzzzz-8i9sb-abcd2bnq7jt7kon
-  owner_uuid: zzzzz-tpzed-xurymjxw79nv3jz
-  cancelled_at: ~
-  cancelled_by_user_uuid: ~
-  cancelled_by_client_uuid: ~
-  script_version: 7def43a4d3f20789dda4700f703b5514cc3ed250
-  script_parameters:
-    input: 1f4b0bc7583c2a7f9102c395f4ffc5e3+45
-  created_at: <%= 4.minute.ago.to_s(:db) %>
-  started_at: <%= 3.minute.ago.to_s(:db) %>
-  finished_at: <%= 2.minute.ago.to_s(:db) %>
-  running: false
-  success: true
-  output: fa7aeb5140e2848d39b416daeef4ffc5+45+K at xyzzy
-  priority: 0
-  log: ea10d51bcf88862dbcc36eb292017dfd+45+K at xyzzy
-  is_locked_by_uuid: ~
-  tasks_summary:
-    failed: 0
-    todo: 0
-    running: 0
-    done: 1
-  runtime_constraints: {}
diff --git a/services/api/test/functional/arvados/v1/jobs_controller_test.rb b/services/api/test/functional/arvados/v1/jobs_controller_test.rb
index e4f70cf..a37c2b6 100644
--- a/services/api/test/functional/arvados/v1/jobs_controller_test.rb
+++ b/services/api/test/functional/arvados/v1/jobs_controller_test.rb
@@ -37,38 +37,38 @@ class Arvados::V1::JobsControllerTest < ActionController::TestCase
     }
     assert_response :success
     assert_not_nil assigns(:object)
-    new_job = JSON.parse(@response.body)
+    new_job = assigns(:object)
     assert_equal 'd41d8cd98f00b204e9800998ecf8427e+0', new_job['log']
     assert_equal 'd41d8cd98f00b204e9800998ecf8427e+0', new_job['output']
     version = new_job['script_version']
 
     # Make sure version doesn't get mangled by normalize
     assert_not_nil version.match(/^[0-9a-f]{40}$/)
-    assert_equal 'master', JSON.parse(@response.body)['supplied_script_version']
+    assert_equal 'master', json_response['supplied_script_version']
   end
 
   test "normalize output and log uuids when updating job" do
     authorize_with :active
 
-    job = jobs(:job_with_unnormalized_output_and_log)
+    foobar_job = jobs(:foobar)
 
+    new_output = 'd41d8cd98f00b204e9800998ecf8427e+0+K at xyzzy'
+    new_log = 'd41d8cd98f00b204e9800998ecf8427e+0+K at xyzzy'
     put :update, {
-      id: job['uuid'],
+      id: foobar_job['uuid'],
       job: {
-        log: job['log']
+        output: new_output,
+        log: new_log
       }
     }
 
-    updated_job = JSON.parse(@response.body)
-    assert_not_equal job['log'], updated_job['log']
-    assert_equal job[:log][0,job['log'].rindex('+')], updated_job['log']
-    assert_not_equal job['output'], updated_job['output']
-    assert_equal job[:output][0,job['output'].rindex('+')], updated_job['output']
-
-    # Make sure version doesn't get mangled by normalize
-    updated_version = updated_job['script_version']
-    assert_not_nil updated_version.match(/^[0-9a-f]{40}$/)
-    assert_equal job['script_version'], updated_version
+    updated_job = json_response
+    assert_not_equal foobar_job['log'], updated_job['log']
+    assert_not_equal new_log, updated_job['log']  # normalized during update
+    assert_equal new_log[0,new_log.rindex('+')], updated_job['log']
+    assert_not_equal foobar_job['output'], updated_job['output']
+    assert_not_equal new_output, updated_job['output']  # normalized during update
+    assert_equal new_output[0,new_output.rindex('+')], updated_job['output']
   end
 
   test "cancel a running job" do

commit 195b23ed7fd0c6261d0a945a9f0e541d78a0648e
Merge: ebdbddd b506247
Author: radhika <radhika at curoverse.com>
Date:   Fri Sep 26 13:35:14 2014 -0400

    Merge branch 'master' into 3889-functional-testing
    
    Conflicts:
    	services/api/test/fixtures/jobs.yml

diff --cc services/api/test/fixtures/jobs.yml
index 017d896,b84922d..fee4379
--- a/services/api/test/fixtures/jobs.yml
+++ b/services/api/test/fixtures/jobs.yml
@@@ -212,28 -222,4 +222,29 @@@ queued
    is_locked_by_uuid: ~
    tasks_summary: {}
    runtime_constraints: {}
+   state: Queued
 +
 +job_with_unnormalized_output_and_log:
 +  uuid: zzzzz-8i9sb-abcd2bnq7jt7kon
 +  owner_uuid: zzzzz-tpzed-xurymjxw79nv3jz
 +  cancelled_at: ~
 +  cancelled_by_user_uuid: ~
 +  cancelled_by_client_uuid: ~
 +  script_version: 7def43a4d3f20789dda4700f703b5514cc3ed250
 +  script_parameters:
 +    input: 1f4b0bc7583c2a7f9102c395f4ffc5e3+45
 +  created_at: <%= 4.minute.ago.to_s(:db) %>
 +  started_at: <%= 3.minute.ago.to_s(:db) %>
 +  finished_at: <%= 2.minute.ago.to_s(:db) %>
 +  running: false
 +  success: true
 +  output: fa7aeb5140e2848d39b416daeef4ffc5+45+K at xyzzy
 +  priority: 0
 +  log: ea10d51bcf88862dbcc36eb292017dfd+45+K at xyzzy
 +  is_locked_by_uuid: ~
 +  tasks_summary:
 +    failed: 0
 +    todo: 0
 +    running: 0
 +    done: 1
 +  runtime_constraints: {}

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list