AC-561 Set host has_inventory_sources flag on import.

This commit is contained in:
Chris Church
2013-10-16 12:57:36 -04:00
parent 2f3409db08
commit a0c6c0e984
2 changed files with 3 additions and 0 deletions

View File

@@ -1004,9 +1004,11 @@ class InventoryUpdatesTest(BaseTransactionTest):
for host in inventory.hosts.all():
source_pks = host.inventory_sources.values_list('pk', flat=True)
self.assertTrue(inventory_source.pk in source_pks)
self.assertTrue(host.has_inventory_sources)
for group in inventory.groups.all():
source_pks = group.inventory_sources.values_list('pk', flat=True)
self.assertTrue(inventory_source.pk in source_pks)
self.assertTrue(group.has_inventory_sources)
def test_update_from_ec2(self):
source_username = getattr(settings, 'TEST_AWS_ACCESS_KEY_ID', '')