self.assertEqual(self.test.publish_artifacts(),
testcase.TestCase.EX_PUBLISH_ARTIFACTS_ERROR)
args[0].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('boto3.resource', side_effect=Exception)
def test_publish_artifacts_exc3(self, *args):
self.assertEqual(self.test.publish_artifacts(),
testcase.TestCase.EX_PUBLISH_ARTIFACTS_ERROR)
args[0].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('boto3.resource')
def test_publish_artifacts_exc4(self, *args):
self.assertEqual(self.test.publish_artifacts(),
testcase.TestCase.EX_PUBLISH_ARTIFACTS_ERROR)
args[0].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('boto3.resource')
def test_publish_artifacts_exc5(self, *args):
self.assertEqual(self.test.publish_artifacts(),
testcase.TestCase.EX_PUBLISH_ARTIFACTS_ERROR)
args[0].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('mimetypes.guess_type', return_value=(None, None))
@mock.patch('boto3.resource')
testcase.TestCase.EX_OK)
args[0].assert_called_once_with(self.test.res_dir)
args[1].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('mimetypes.guess_type', return_value=(None, None))
@mock.patch('boto3.resource')
testcase.TestCase.EX_OK)
args[0].assert_called_once_with(self.test.res_dir)
args[1].assert_called_once_with(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY)
+ 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'])
@mock.patch('mimetypes.guess_type', return_value=(None, None))
@mock.patch('os.path.exists', return_value=True)
testcase.TestCase.EX_OK)
args[0].assert_called_once_with(self.test.res_dir)
expected = [
- mock.call(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY),
+ mock.call('s3', endpoint_url=os.environ['S3_ENDPOINT_URL']),
mock.call().meta.client.head_bucket(Bucket='xtesting'),
mock.call().Bucket('xtesting'),
mock.call().Bucket().upload_file(
testcase.TestCase.EX_OK)
args[0].assert_called_once_with(self.test.res_dir)
expected = [
- mock.call(
- 's3', endpoint_url=os.environ['S3_ENDPOINT_URL'],
- config=mock.ANY),
+ mock.call('s3', endpoint_url=os.environ['S3_ENDPOINT_URL']),
mock.call().meta.client.head_bucket(Bucket='xtesting'),
mock.call().Bucket('xtesting'),
mock.call().Bucket().upload_file(