def testLajiStoreDevice(self): response = LajiStoreAPI.post_device(**self.device) self.assertEquals(True, "id" in response) response = LajiStoreAPI.get_device(response["id"]) self.assertEquals(True, "id" in response) self.device["id"] = response["id"] response = LajiStoreAPI.update_device(**self.device) self.assertEquals(True, "id" in response) response = LajiStoreAPI.delete_device(response["id"]) self.assertEquals(204, response.status_code)
def delete(self): ''' Deletes the device from LajiStore. Note that the object is not destroyed! ''' LajiStoreAPI.delete_device(self.id)