Revision c2f037ff snf-tools/synnefo_tools/burnin/images_tests.py

b/snf-tools/synnefo_tools/burnin/images_tests.py
42 42

  
43 43
from kamaki.clients import ClientError
44 44

  
45
from synnefo_tools.burnin.common import BurninTests, Proper
45
from synnefo_tools.burnin.common import BurninTests, Proper, \
46
    QPITHOS, QADD, QREMOVE
46 47

  
47 48

  
48 49
# pylint: disable=too-many-public-methods
......
171 172
            self.clients.pithos.upload_object(self.temp_image_name, fin)
172 173

  
173 174
        # Verify quotas
174
        self._check_quotas(diskspace=file_size)
175
        changes = \
176
            {self._get_uuid(): [(QPITHOS, QADD, file_size, None)]}
177
        self._check_quotas(changes)
175 178

  
176 179
    def test_009_register_image(self):
177 180
        """Register image to Plankton"""
......
198 201
        self.clients.pithos.del_object(self.temp_image_name)
199 202
        # Verify quotas
200 203
        file_size = os.path.getsize(self.temp_image_file)
201
        self._check_quotas(diskspace=-file_size)
204
        changes = \
205
            {self._get_uuid(): [(QPITHOS, QREMOVE, file_size, None)]}
206
        self._check_quotas(changes)
202 207
        self.temp_image_name = None
203 208
        # Remove temp directory
204 209
        self.info("Deleting temp directory %s", self.temp_dir)

Also available in: Unified diff