[ARVADOS] updated: 32a058657ee1445c4a1c86368ede5287d6274f98

git at public.curoverse.com git at public.curoverse.com
Thu Sep 25 08:34:16 EDT 2014


Summary of changes:
 apps/workbench/test/functional/actions_controller_test.rb    | 12 ++++--------
 .../workbench/test/functional/collections_controller_test.rb |  4 ++--
 2 files changed, 6 insertions(+), 10 deletions(-)

       via  32a058657ee1445c4a1c86368ede5287d6274f98 (commit)
      from  8a833d4bb82249d3f2b9c0473c0af51db92fdc72 (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 32a058657ee1445c4a1c86368ede5287d6274f98
Author: radhika <radhika at curoverse.com>
Date:   Thu Sep 25 08:15:08 2014 -0400

    3889: Fix two functional tests that were performing multiple actions on a single instance of TestCase object.

diff --git a/apps/workbench/test/functional/actions_controller_test.rb b/apps/workbench/test/functional/actions_controller_test.rb
index d152a00..0e28b06 100644
--- a/apps/workbench/test/functional/actions_controller_test.rb
+++ b/apps/workbench/test/functional/actions_controller_test.rb
@@ -26,16 +26,12 @@ class ActionsControllerTest < ActionController::TestCase
          session_for(:active))
 
     assert_response 302   # collection created and redirected to new collection page
-    new_collection_uuid = response.headers['Location'].split('/')[-1]
-
-    @controller = CollectionsController.new
 
-    get :show, {
-      id: new_collection_uuid
-    }
-    assert_response :success
+    assert response.headers['Location'].include? '/collections/'
+    new_collection_uuid = response.headers['Location'].split('/')[-1]
 
-    collection = assigns(:object)
+    use_token :active
+    collection = Collection.select([:uuid, :manifest_text]).where(uuid: new_collection_uuid).first
     manifest_text = collection['manifest_text']
     assert manifest_text.include?('foo'), 'Not found foo in new collection manifest text'
     assert manifest_text.include?('bar'), 'Not found bar in new collection manifest text'
diff --git a/apps/workbench/test/functional/collections_controller_test.rb b/apps/workbench/test/functional/collections_controller_test.rb
index 8c6aeab..674e908 100644
--- a/apps/workbench/test/functional/collections_controller_test.rb
+++ b/apps/workbench/test/functional/collections_controller_test.rb
@@ -102,8 +102,8 @@ class CollectionsControllerTest < ActionController::TestCase
 
   test "reader token Collection links end with trailing slash" do
     # Testing the fix for #2937.
-    show_collection(:foo_file, :active_trustedclient)
-    post(:share, collection_params(:foo_file))
+    session = session_for(:active_trustedclient)
+    post(:share, collection_params(:foo_file), session)
     assert(@controller.download_link.ends_with? '/',
            "Collection share link does not end with slash for wget")
   end

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list