public void testOwnerInfoOneOfEachEntitlement() {
ConsumerType type = consumerTypeCurator.lookupByLabel("system");
Consumer consumer = new Consumer("test-consumer", "test-user", owner, type);
consumerCurator.create(consumer);
EntitlementCertificate cert = createEntitlementCertificate("fake", "fake");
Entitlement entitlement = createEntitlement(owner, consumer, pool1, cert);
entitlement.setQuantity(1);
entitlementCurator.create(entitlement);
type = consumerTypeCurator.lookupByLabel("domain");
consumer = new Consumer("test-consumer", "test-user", owner, type);
consumerCurator.create(consumer);
cert = createEntitlementCertificate("fake", "fake");
entitlement = createEntitlement(owner, consumer, pool1, cert);
entitlement.setQuantity(1);
entitlementCurator.create(entitlement);
OwnerInfo info = ownerInfoCurator.lookupByOwner(owner);
Map<String, Integer> expectedConsumers = new HashMap<String, Integer>() {