

def setUp(self):
    super(TestCreatingLocations, self).setUp()
    moxfixture = self.useFixture(moxstubout.MoxStubout())
    self.stubs = moxfixture.stubs
    conf = copy.deepcopy(SWIFT_CONF)
    self.store = Store(self.conf)
    self.config(**conf)
    moves.reload_module(swift)
    self.addCleanup(self.conf.reset)
    service_catalog = [{
        'endpoint_links': [],
        'endpoints': [{
            'adminURL': 'https://some_admin_endpoint',
            'region': 'RegionOne',
            'internalURL': 'https://some_internal_endpoint',
            'publicURL': 'https://some_endpoint',
        }],
        'type': 'object-store',
        'name': 'Object Storage Service',
    }]
    self.ctxt = mock.MagicMock(user='user', tenant='tenant', auth_token='123', service_catalog=service_catalog)

dataset/ETHPy150Open openstack/glance_store/glance_store/tests/unit/test_swift_store.py TestCreatingLocations.setUp/original