use of org.candlepin.model.ConsumerContentOverride in project candlepin by candlepin.
the class ConsumerBindUtil method handleActivationKeyOverrides.
private void handleActivationKeyOverrides(Consumer consumer, Set<ActivationKeyContentOverride> overrides) {
for (ActivationKeyContentOverride akco : overrides) {
ConsumerContentOverride consumerOverride = akco.buildConsumerContentOverride(consumer);
this.consumerContentOverrideCurator.addOrUpdate(consumer, consumerOverride);
}
}
use of org.candlepin.model.ConsumerContentOverride in project candlepin by candlepin.
the class ConsumerContentOverrideResourceTest method testAddOverride.
@Test
public void testAddOverride() {
List<ContentOverride> entries = new LinkedList<>();
ConsumerContentOverride toAdd = new ConsumerContentOverride(consumer, "label", "overridename", "overridevalue");
entries.add(toAdd);
resource.addContentOverrides(context, principal, entries);
Mockito.verify(consumerContentOverrideCurator, Mockito.times(1)).addOrUpdate(consumer, toAdd);
}
Aggregations