Esempio n. 1
0
    def test_context_conflict_between_boto_and_boto3_utils(self):
        botomod.assign_funcs(__name__, 'ec2')
        boto3mod.assign_funcs(__name__, 'ec2', get_conn_funcname="_get_conn3")

        boto_ec2_conn = botomod.get_connection('ec2',
                                                       region=region,
                                                       key=secret_key,
                                                       keyid=access_key)
        boto3_ec2_conn = boto3mod.get_connection('ec2',
                                                         region=region,
                                                         key=secret_key,
                                                         keyid=access_key)

        # These should *not* be the same object!
        self.assertNotEqual(id(boto_ec2_conn), id(boto3_ec2_conn))
Esempio n. 2
0
    def test_context_conflict_between_boto_and_boto3_utils(self):
        botomod.assign_funcs(__name__, "ec2")
        boto3mod.assign_funcs(__name__, "ec2", get_conn_funcname="_get_conn3")

        boto_ec2_conn = botomod.get_connection("ec2",
                                               region=region,
                                               key=secret_key,
                                               keyid=access_key)
        boto3_ec2_conn = boto3mod.get_connection("ec2",
                                                 region=region,
                                                 key=secret_key,
                                                 keyid=access_key)

        # These should *not* be the same object!
        assert id(boto_ec2_conn) != id(boto3_ec2_conn)