[ARVADOS] updated: 1c3f80531764931c241cd07a3cbc56892b645bce
Git user
git at public.curoverse.com
Tue Jul 19 16:10:53 EDT 2016
Summary of changes:
sdk/python/tests/test_arv_put.py | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
via 1c3f80531764931c241cd07a3cbc56892b645bce (commit)
from e3a7370e35792c4cdfae441099d18d1b0d18e5b3 (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 1c3f80531764931c241cd07a3cbc56892b645bce
Author: Lucas Di Pentima <lucas at curoverse.com>
Date: Tue Jul 19 17:09:38 2016 -0300
9463: Updated integration test to mock current implementation
diff --git a/sdk/python/tests/test_arv_put.py b/sdk/python/tests/test_arv_put.py
index 19d128a..5a4269b 100755
--- a/sdk/python/tests/test_arv_put.py
+++ b/sdk/python/tests/test_arv_put.py
@@ -465,16 +465,14 @@ class ArvadosPutTest(run_test_server.TestCaseWithServers, ArvadosBaseTestCase):
['--project-uuid', self.Z_UUID, '--stream'])
def test_api_error_handling(self):
- collections_mock = mock.Mock(name='arv.collections()')
- coll_create_mock = collections_mock().create().execute
- coll_create_mock.side_effect = arvados.errors.ApiError(
+ coll_save_mock = mock.Mock(name='arv.collection.Collection().save_new()')
+ coll_save_mock.side_effect = arvados.errors.ApiError(
fake_httplib2_response(403), '{}')
- arv_put.api_client = arvados.api('v1')
- arv_put.api_client.collections = collections_mock
+ arvados.collection.Collection.save_new = coll_save_mock
with self.assertRaises(SystemExit) as exc_test:
self.call_main_with_args(['/dev/null'])
self.assertLess(0, exc_test.exception.args[0])
- self.assertLess(0, coll_create_mock.call_count)
+ self.assertLess(0, coll_save_mock.call_count)
self.assertEqual("", self.main_stdout.getvalue())
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list