def setUp(self): super(TestPlacementAPIClient, self).setUp() config = mock.Mock() config.region_name = 'region_name' self.openstack_api_version = (placement.PLACEMENT_API_LATEST_SUPPORTED) self.placement_api_client = placement.PlacementAPIClient( config, self.openstack_api_version) self.placement_fixture = self.useFixture( fixture.PlacementAPIClientFixture(self.placement_api_client))
def setUp(self): super(TestPlacementAPIClient, self).setUp() config = mock.Mock() config.region_name = 'region_name' self.openstack_api_version = 'version 1.1' self.placement_api_client = placement.PlacementAPIClient( config, self.openstack_api_version) self.placement_fixture = self.useFixture( fixture.PlacementAPIClientFixture(self.placement_api_client))
def _create_client_and_fixture(self): placement_client = placement.PlacementAPIClient(mock.Mock()) placement_fixture = self.useFixture( fixture.PlacementAPIClientFixture(placement_client)) return placement_client, placement_fixture