Ejemplo n.º 1
0
    def setUpClass(self):
        self.resource = resource()
        self.client = ProfitBricksService(username=configuration.USERNAME,
                                          password=configuration.PASSWORD,
                                          headers=configuration.HEADERS)

        ipblock1 = IPBlock(**self.resource['ipblock'])
        ipblock1.size = 2
        self.ipblock1 = self.client.reserve_ipblock(ipblock1)

        ipblock2 = IPBlock(**self.resource['ipblock'])
        self.ipblock2 = self.client.reserve_ipblock(ipblock2)
    def setUpClass(cls):
        cls.resource = resource()
        cls.client = ProfitBricksService(
            username=configuration.USERNAME,
            password=configuration.PASSWORD,
            headers=configuration.HEADERS)

        ipblock1 = IPBlock(**cls.resource['ipblock'])
        ipblock1.size = 2
        cls.ipblock1 = cls.client.reserve_ipblock(ipblock1)

        ipblock2 = IPBlock(**cls.resource['ipblock'])
        cls.ipblock2 = cls.client.reserve_ipblock(ipblock2)