Merge pull request #1138 from coreos-inc/torrentgc

Add GC test for torrent info
This commit is contained in:
josephschorr 2016-01-12 12:16:47 -05:00
commit 9d6c7260f9

View file

@ -43,6 +43,13 @@ class TestGarbageCollection(unittest.TestCase):
model.image.find_or_create_derived_storage(image, 'squash', preferred)
model.image.find_or_create_derived_storage(image, 'aci', preferred)
# Add some torrent info.
try:
model.storage.save_torrent_info(image.storage, 1, 'helloworld')
model.storage.save_torrent_info(image.storage, 2, 'helloworlds!')
except:
pass
# Add some additional placements to the image.
for location_name in ['local_eu']:
location = database.ImageStorageLocation.get(name=location_name)