Add 'apps/arv-web/' from commit 'f9732ad8460d013c2f28363655d0d1b91894dca5'
[arvados.git] / apps / workbench / test / unit / arvados_resource_list_test.rb
index 6494bc524f3218b8d07d1e4dca38e03e56224949..a3bfbc19f4105918f453f4baf1ab0d0ffda13c5c 100644 (file)
@@ -80,4 +80,15 @@ class ResourceListTest < ActiveSupport::TestCase
     assert_equal c.result_limit, a
   end
 
+  test 'get empty set' do
+    use_token :admin
+    c = Collection.
+      where(owner_uuid: 'doesn-texis-tdoesntexistdoe').
+      fetch_multiple_pages(false)
+    # Important: check c.result_offset before calling c.results here.
+    assert_equal 0, c.result_offset
+    assert_equal 0, c.items_available
+    assert_empty c.results
+  end
+
 end