From a5afacf62a1985c352be381c559cb1caf367e8b8 Mon Sep 17 00:00:00 2001 From: Feanil Patel Date: Wed, 31 Jul 2019 17:00:47 -0400 Subject: [PATCH] These tests don't test anything interesting. They are running into issues because of a bug in moto but looking closer at what they are testing. Both tests test the happy path of the underlying function. In the happy path scenario all boto calls succeed and all theses test do is test that but with all the boto calls mocked out. So we're just testing whether the mock is a good mock of boto which is not useful. --- pavelib/paver_tests/test_database.py | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/pavelib/paver_tests/test_database.py b/pavelib/paver_tests/test_database.py index 052004922e..acfceaa725 100644 --- a/pavelib/paver_tests/test_database.py +++ b/pavelib/paver_tests/test_database.py @@ -21,25 +21,6 @@ from pavelib.utils.envs import Env from .utils import PaverTestCase -class TestPaverDbS3Utils(MockS3Mixin, TestCase): - """ Tests for paver bokchoy database utils related to s3 """ - def setUp(self): - super(TestPaverDbS3Utils, self).setUp() - conn = boto.connect_s3() - conn.create_bucket('moto_test_bucket') - self.bucket = conn.get_bucket('moto_test_bucket') - - def test_fingerprint_in_bucket(self): - key = boto.s3.key.Key(bucket=self.bucket, name='testfile.tar.gz') - key.set_contents_from_string('this is a test') - self.assertTrue(is_fingerprint_in_bucket('testfile', 'moto_test_bucket')) - - def test_fingerprint_not_in_bucket(self): - key = boto.s3.key.Key(bucket=self.bucket, name='testfile.tar.gz') - key.set_contents_from_string('this is a test') - self.assertFalse(is_fingerprint_in_bucket('otherfile', 'moto_test_bucket')) - - class TestPaverDbUtils(TestCase): """ Tests for paver bokchoy database utils """ @patch('pavelib.utils.db_utils.verify_files_exist')