theforeman / foreman-ansible-modules

Ansible modules for interacting with the Foreman API and various plugin APIs such as Katello
GNU General Public License v3.0
147 stars 164 forks source link

Write Tests for adding subscriptions to activation keys via Pool ID #540

Open wbclark opened 4 years ago

wbclark commented 4 years ago
SUMMARY

In https://github.com/theforeman/foreman-ansible-modules/pull/529 we are adding the functionality to specify subscriptions by Pool ID when adding subscriptions to activation keys. This needs to have associated tests.

However in order to write the test for this one, we need to retrieve the Pool ID for a subscription dynamically, since it will vary in each Katello installation even when using the same manifest. Therefore we are blocked until https://github.com/theforeman/foreman-ansible-modules/pull/537 is merged, since we need to be able to search by organization or organization-id in order to obtain the correct pool_id for the test.

ISSUE TYPE
evgeni commented 4 years ago

@m-czernek and I added params and organization to search_facts, so the tests should be doable now.