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

Remove cli.factory dependencies from the repo #11544

Merged
merged 1 commit into from
Nov 20, 2023

Conversation

shweta83
Copy link
Contributor

@shweta83 shweta83 commented May 26, 2023

This PR will remove the dependency of cli.factory from robottelo and cli_factory will be used in place of that.
All the test modules using cli.factory method should be replaced with cli_factory methods as we are deprecating cli.factory.

Old methods -> New methods

make_activation_key -> make_activation_key
make_architecture -> make_architecture
make_content_view -> make_content_view
make_content_view_with_credentials -> content_view_with_credentials
make_content_view_filter -> content_view_filter
make_content_view_filter_rule -> content_view_filter_rule
make_discoveryrule -> discoveryrule
make_content_credential -> make_content_credential
make_location -> make_location
make_model -> model
make_partition_table -> make_partition_table
make_product -> make_product
make_product_with_credentials -> product_with_credentials
make_product_wait -> make_product_wait
make_repository_with_credentials -> repository_with_credentials
make_role -> role
make_filter -> make_filter
make_scap_policy -> scap_policy
make_subnet -> subnet
make_sync_plan -> sync_plan
make_host -> make_host
make_fake_host -> make_fake_host
make_host_collection -> host_collection
make_job_invocation -> job_invocation
make_job_invocation_with_credentials -> Removed as not used anywhere
make_job_template -> job_template
make_user -> user
make_usergroup -> usergroup
make_usergroup_external --> usergroup_external
make_compute_resource -> compute_resource
make_org -> make_org
make_org_with_credentials -> org_with_credentials
make_realm -> realm
make_reporttemplate -> reporttemplate
make_os -> os
make_scapcontent -> scapcontent
make_domain -> make_domain
make_hostgroup -> hostgroup
make_medium -> make_medium
make_environment -> ?
make_lifecycle_environment -> make_lifecycle_environment
make_tailoringfile -> tailoringfile
make_template -> make_template
make_template_input -> template_input
make_virt_who_config -> virt_who_config
activationkey_add_subscription_to_repo -> activationkey_add_subscription_to_repo
setup_org_for_a_custom_repo -> setup_org_for_a_custom_repo
_setup_org_for_a_rh_repo -> _setup_org_for_a_rh_repo
setup_org_for_a_rh_repo -> setup_org_for_a_rh_repo
add_role_permissions -> add_role_permissions
setup_cdn_and_custom_repositories -> setup_cdn_and_custom_repositories
setup_cdn_and_custom_repos_content -> setup_cdn_and_custom_repos_content
make_http_proxy -> Not used anywhere

@shweta83 shweta83 marked this pull request as draft May 26, 2023 06:19
@shweta83 shweta83 force-pushed the cli_factory_gone branch from 36a9477 to be44675 Compare May 26, 2023 06:19
@shweta83 shweta83 added 6.11.z Introduced in or relating directly to Satellite 6.11 CherryPick PR needs CherryPick to previous branches 6.12.z Introduced in or relating directly to Satellite 6.12 AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing 6.13.z Introduced in or relating directly to Satellite 6.13 Framework Changes A modification of the robottelo framework labels May 26, 2023
Copy link
Member

@jyejare jyejare left a comment

Choose a reason for hiding this comment

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

We are not suppose to use 'cli/factory' module at all. Everything related CLI helpers should be coming from 'cli_factory' object.

@jyejare jyejare added the 6.14.z Introduced in or relating directly to Satellite 6.14 label Jun 1, 2023
@github-actions
Copy link

This pull request has not been updated in the past 45 days.

@github-actions github-actions bot added the Stale Stale issue or Pull Request label Jul 17, 2023
@jyejare
Copy link
Member

jyejare commented Jul 18, 2023

@shweta83 Are you ok to resume on this ?

Just FYI, Automation FG is planning for this kind of cleanup in Q3, this PR would be considered one of them.

@shweta83
Copy link
Contributor Author

nning for this kind of cleanup in Q3, this PR

Yes. I am planning to resume this in later this week.

@github-actions github-actions bot removed the Stale Stale issue or Pull Request label Jul 19, 2023
@github-actions
Copy link

github-actions bot commented Sep 3, 2023

This pull request has not been updated in the past 45 days.

@github-actions github-actions bot added the Stale Stale issue or Pull Request label Sep 3, 2023
@jyejare jyejare removed the Stale Stale issue or Pull Request label Sep 4, 2023
@shweta83 shweta83 force-pushed the cli_factory_gone branch 4 times, most recently from ffae036 to 33bb1cf Compare September 20, 2023 06:12
@shweta83 shweta83 marked this pull request as ready for review September 20, 2023 06:12
@shweta83 shweta83 requested review from a team as code owners September 20, 2023 06:12
@shweta83 shweta83 changed the title Remove cli_factory dependencies from the repo Remove cli.factory dependencies from the repo Sep 20, 2023
@shweta83 shweta83 requested a review from jyejare September 20, 2023 06:18
Copy link
Member

@jyejare jyejare left a comment

Choose a reason for hiding this comment

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

@shweta83 Looks like the changes made here are doing the opposite of what we are supposed to do :)

Please refer comments or else we can sync up !

robottelo/cli/factory.py Outdated Show resolved Hide resolved
robottelo/host_helpers/cli_factory.py Outdated Show resolved Hide resolved
robottelo/host_helpers/repository_mixins.py Outdated Show resolved Hide resolved
tests/foreman/api/test_location.py Outdated Show resolved Hide resolved
tests/foreman/cli/test_activationkey.py Outdated Show resolved Hide resolved
tests/foreman/cli/test_activationkey.py Outdated Show resolved Hide resolved
tests/foreman/cli/test_activationkey.py Outdated Show resolved Hide resolved
tests/foreman/cli/test_activationkey.py Outdated Show resolved Hide resolved
tests/foreman/cli/test_capsule.py Outdated Show resolved Hide resolved
tests/foreman/ui/test_activationkey.py Outdated Show resolved Hide resolved
Griffin-Sullivan pushed a commit that referenced this pull request Dec 21, 2023
shweta83 added a commit to shweta83/robottelo that referenced this pull request Apr 10, 2024
shweta83 pushed a commit to shweta83/robottelo that referenced this pull request Apr 10, 2024
@pondrejk pondrejk mentioned this pull request May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.12.z Introduced in or relating directly to Satellite 6.12 6.13.z Introduced in or relating directly to Satellite 6.13 6.14.z Introduced in or relating directly to Satellite 6.14 AutoMerge_Cherry_Picked The cherrypicked PRs of master PR would be automerged if all checks passing CherryPick PR needs CherryPick to previous branches Framework Changes A modification of the robottelo framework
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants