Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1370508: Custom products in Activation key are not subscribed when service_level is set #1343

Merged
merged 1 commit into from Sep 21, 2016

Conversation

pjonastik
Copy link
Contributor

No description provided.

@wottop wottop self-assigned this Sep 14, 2016
@wottop
Copy link
Member

wottop commented Sep 14, 2016

can you go ahead an merge the commits?

Previously this scenario was blocked by rule. Seems that a product
without a support_level attribute should be usable by anyone, not
just those without a service level assignment.

In addition, 3 spec tests added in order to verify correct behavior.
@pjonastik
Copy link
Contributor Author

@wottop I've merged commits.

sub_custom_product = @cp.create_subscription(@owner['key'], custom_product['id'], 30)

# creating in order to be able set SLA on activation key
premium_product = create_product('testp2', 'testp2', {:attributes => {:support_level => 'Premium'}})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This product has a support level set, but the test says 'custom product without SLA'

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are two products: with SLA set = premium_product and without SLA set = custom_product.
In test you can see that only custom_product is assigned to activation_key.
Premium_product exists (as comment above explain) because of setting SLA on activation key. It's not possible set SLA on activation key to 'Premium' value without creation of subscription of premium_product.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point

@wottop
Copy link
Member

wottop commented Sep 21, 2016

ack

@wottop wottop merged commit e305379 into candlepin-0.9.54-HOTFIX Sep 21, 2016
@wottop wottop deleted the pjonasti/1370508 branch September 21, 2016 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants