Robottelo¶
Robottelo is a test suite which exercises The Foreman. All tests are automated, suited for use in a continuous integration environment, and data driven. There are three types of tests:
Quickstart¶
The following is only a brief setup guide for Robottelo. The section on Running the Tests provides a more comprehensive guide to using Robottelo.
Robottelo requires SSH access to the Satellite 6 system under test, and this SSH access is implemented by Paramiko. Install the headers for the following to ensure that Paramiko’s dependencies build correctly:
OpenSSL
Python development headers
libffi
Recommendation: Create a virtual python environment for the following setup.
Create virtual environment for python 3.x:: $ python3 -m venv <venv_name> To activate virtual environment: $ source <venv_name>/bin/activate To end the session: $ deactivate
On Fedora, you can install these with the following command:
For python3.x:
dnf install -y gcc git libffi-devel openssl-devel python38-devel redhat-rpm-config libcurl-devel libxml2-devel
On Red Hat Enterprise Linux 7, you can install these with the following command:
yum install -y gcc git libffi-devel openssl-devel python38-devel redhat-rpm-config libcurl-devel libxml2-devel
For more information, see Paramiko: Installing.
Get the source code and install dependencies:
$ git clone git://github.com/SatelliteQE/robottelo.git
$ export PYCURL_SSL_LIBRARY=<ssl library>
$ pip install -r requirements.txt
Notes: * To determine ssl library, check http://pycurl.io/docs/latest/install.html#ssl
That’s it! You can now go ahead and start testing The Foreman. However, there are a few other things you may wish to do before continuing:
1. You may want to install development tools (such as gcc) for your OS. If
running Fedora or Red Hat Enterprise Linux, execute yum groupinstall
"Development Tools"
. Make sure to use dnf
instead of yum
if
dnf
is available on your system.
2. You may wish to install the optional dependencies listed in
requirements-optional.txt
. (Use pip, as shown above.) They are required
for tasks like working with certificates, running the internal robottelo test
suite and checking code quality with pre-commit.
Robottelo on Docker¶
Robottelo is also available on dockerhub.:
$ docker pull satelliteqe/robottelo
It also can be built locally using the Dockerfile, in the main directory.:
$ docker build -t robottelo .
In order to run tests, you will need to mount your robottelo.properties file.:
$ docker run -v {path to robottelo dir}/robottelo.properties:/robottelo/robottelo.properties satelliteqe/robottelo <test command>
You can also mount the entire robottelo directory to include the properties file and any new tests you have written.:
$ docker run -it -v {path to robottelo dir}:/robottelo satelliteqe/robottelo /bin/bash
Notes:
CLI tests run easiest if you include the root credentials in server.yaml
UI tests should be configured to run through your SauceLabs account.
Running the Tests¶
Before running any tests, you must create a configuration file:
$ cp virtwho.properties.sample ./virtwho.properties
$ vi virtwho.properties
$ cd conf
$ cp broker.yaml.template ./broker.yaml
$ vi broker.yaml
$ cp robottelo.yaml.template ./robottelo.yaml
$ vi robottelo.yaml
$ cp server.yaml.template ./server.yaml
$ vi server.yaml
That done, you can run tests using make
:
$ make test-robottelo
$ make test-docstrings
$ make test-foreman-api
$ make test-foreman-cli
$ make test-foreman-ui
$ make test-foreman-smoke
Robottelo provides two test suites, one for testing Robottelo itself and another for testing Foreman/Satellite 6. Robottelo’s tests are under the tests/robottelo directory and the Foreman/Satellite 6 tests are under the tests/foreman directory.
If you want to run tests without the aid of make
, you can do that with
either pytest , unittest or nose. Just specify the path for the test suite you
want to run:
$ pytest tests/robottelo
$ pytest tests/foreman
$ python -m unittest discover -s tests/robottelo -t .
$ python -m unittest discover -s tests/foreman -t .
$ nosetests tests/robottelo
$ nosetests tests/foreman
The following sections discuss, in detail, how to update the configuration file and run tests directly.
Initial Configuration¶
To configure Robottelo, multiple template yaml files are present to execute different test cases in Robottelo. 1. server.yaml : Populate server.yaml with ssh credentials and ssh key path. Then, edit the configuration file so that at least the following attributes are set:
HOSTNAMES=[LIST OF FULLY QUALIFIED DOMAIN NAMES OR IP ADDRESSES] SSH_USERNAME=[SSH USERNAME] SSH_PASSWORD=[SSH PASSWORD] / SSH_KEY=[PATH TO YOUR SSH KEY] / SSH_KEY_STRING = [SSH KEY AS STRING]
Note that you only need to configure the SSH key if you want to run CLI tests. There are other settings to configure what web browser to use for UI tests and even configuration to run the automation using SauceLabs. For more information about what web browsers you can use, check Selenium’s WebDriver documentation.
Using environment variables¶
Each of the sections in the robottelo.properties
file can be mapped to an
environment variable prefixed with ROBOTTELO_
so for example if you want
to override the server.hostname
without changing the properties file you can do:
$ export ROBOTTELO_SERVER_HOSTNAME=other.hostname.com
The envars follows the format ROBOTTELO_{SECTION}_{VALUE}
all uppercase, more examples:
$ export ROBOTTELO_SERVER_SSH_KEY=path/to/your/key
$ export ROBOTTELO_BUGZILLA_API_KEY=sdfsdg654g8df4gdf6g4df8g468dfg
Running the UI Tests in headless mode¶
You can run browser for UI tests in headless mode by setting browser option in
robottelo.properties
file. Currently it is supported only for chrome
browseroptions=headless
Testing With Pytest¶
To run all tests:
$ pytest
It is possible to run a specific subset of tests:
$ pytest test_case.py
$ pytest test_case.py::TestClass
$ pytest test_case.py::TestClass::test_case_name
To get more verbose output, or run multiple tests:
$ pytest tests/ -v
$ pytest tests/robottelo/test_decorators.py \
tests/robottelo/test_cli.py
To test The Foreman’s API, CLI or UI, use the following commands respectively:
$ pytest tests/foreman/api/
$ pytest tests/foreman/cli/
$ pytest tests/foreman/ui/
To collect from three directories in one run:
$ pytest tests/foreman/{cli,api,ui}/test_host.py
To search in testcase names, in this case it will run just negative tests:
$ pytest tests/foreman/cli/test_host.py -k negative
To run tests in several threads, in this case 4:
$ pytest tests/foreman/cli/test_host.py -n 4
For more information about Python’s pytest module, read the documentation.
Testing With Unittest¶
To run all tests:
$ python -m unittest discover \
–start-directory tests/ –top-level-directory .
It is possible to run a specific subset of tests:
$ python -m unittest tests.robottelo.test_decorators
$ python -m unittest tests.robottelo.test_decorators.DataDecoratorTestCase
$ python -m unittest tests.robottelo.test_decorators.DataDecoratorTestCase.test_data_decorator_smoke
To get more verbose output, or run multiple tests:
$ python -m unittest discover -s tests/ -t . -v
$ python -m unittest \
tests.robottelo.test_decorators tests.robottelo.test_cli
To test The Foreman’s API, CLI or UI, use the following commands respectively:
$ python -m unittest discover -s tests/foreman/api/
$ python -m unittest discover -s tests/foreman/cli/
$ python -m unittest discover -s tests/foreman/ui/
For more information about Python’s unittest module, read the documentation.
Testing With Nose¶
You must have nose installed to execute the nosetests
command.
To run all tests:
$ nosetests
It is possible to run a specific subset of tests:
$ nosetests tests.robottelo.test_decorators
$ nosetests tests.robottelo.test_decorators:DataDecoratorTestCase
$ nosetests tests.robottelo.test_decorators:DataDecoratorTestCase.test_data_decorator_smoke
To get more verbose output, or run multiple tests:
$ nosetests -v
$ nosetests tests.robottelo.test_decorators tests.robottelo.test_cli
To test The Foreman’s API, CLI or UI, use the following commands respectively:
$ nosetests tests.foreman.api
$ nosetests tests.foreman.cli
$ nosetests tests.foreman.ui
Many of the existing tests use subTest to allow for a more data-driven
methodology. In order to run a specific test you need to override the way
nosetests
discovers test names. For instance, if you wanted to run only the
test_positive_create_1
data-driven tests for the foreman.cli.test_org
module:
$ nosetests -m test_positive_create_1 tests.foreman.cli.test_org
Running UI Tests On a Docker Browser¶
It is possible to run UI tests within a docker container. To do this:
Install docker. It is provided by the
docker
package on Fedora and Red
Hat. Be aware that the package may call docker-io
on old OS releases.
* Make sure that docker is up and running and the user that will run robottelo
has permission to run docker commands. For more information check the docker
installation guide https://docs.docker.com/engine/installation/.
* Pull the selenium/standalone-firefox
image
* Set browser=docker
at the [robottelo]
section in the configuration
file robottelo.properties
.
Once you’ve performed these steps, UI tests will no longer launch a web browser on your system. Instead, UI tests launch a web browser within a docker container.
Running UI Tests On SauceLabs¶
It is possible to run UI tests on SauceLabs. To do this:
Set
browser=saucelabs
at the[robottelo]
section in the configuration
file robottelo.properties
.
* Select the browser type by setting webdriver
at the [robottelo]
section in the configuration file. Valid values are firefox
, chrome
and ie
.
* Fill saucelabs_user
and saucelabs_key
at the [robottelo]
section
in the configuration file with your Sauce OnDemand credentials.
* If the machine where Satellite 6 is installed is on a VPN or behind a
firewall make sure to have SauceConnect running.
Miscellany¶
- API Reference
robottelo
- Subpackages
robottelo.api
- Submodules
robottelo.api.utils
- Module Contents
- Classes
- Functions
- call_entity_method_with_timeout
- enable_rhrepo_and_fetchid
- promote
- upload_manifest
- publish_puppet_module
- delete_puppet_class
- create_sync_custom_repo
- enable_sync_redhat_repo
- cv_publish_promote
- one_to_one_names
- one_to_many_names
- configure_provisioning
- create_role_permissions
- wait_for_tasks
- wait_for_syncplan_tasks
- wait_for_errata_applicability_task
- create_discovered_host
- update_vm_host_location
- check_create_os_with_title
- attach_custom_product_subscription
- templateupdate
- update_provisioning_template
- apply_package_filter
- create_org_admin_role
- create_org_admin_user
- skip_yum_update_during_provisioning
- set_hammer_api_timeout
- update_rhsso_settings_in_satellite
- Module Contents
- Submodules
robottelo.cli
- Submodules
robottelo.cli.activationkey
robottelo.cli.admin
robottelo.cli.ansible
robottelo.cli.architecture
robottelo.cli.arfreport
robottelo.cli.auth
robottelo.cli.base
robottelo.cli.capsule
robottelo.cli.computeprofile
robottelo.cli.computeresource
robottelo.cli.content_credentials
robottelo.cli.contentview
- Module Contents
- Classes
- ContentViewFilterRule
- ContentViewFilter
- ContentView
- command_base
- filter
- add_repository
- add_version
- copy
- publish
- version_info
- version_incremental_update
- puppet_module_add
- puppet_module_list
- puppet_module_remove
- version_list
- version_promote
- version_export
- version_import
- version_delete
- remove_from_environment
- remove
- remove_version
- remove_repository
- component_add
- component_list
- Classes
- Module Contents
robottelo.cli.defaults
robottelo.cli.discoveredhost
robottelo.cli.discoveryrule
robottelo.cli.docker
robottelo.cli.domain
robottelo.cli.environment
robottelo.cli.erratum
robottelo.cli.fact
robottelo.cli.factory
- Module Contents
- Functions
- Attributes
- logger
- ORG_KEYS
- CONTENT_VIEW_KEYS
- LIFECYCLE_KEYS
- CLIFactoryError
- create_object
- _entity_with_credentials
- make_activation_key
- make_architecture
- make_content_view
- make_content_view_with_credentials
- make_content_view_filter
- make_content_view_filter_rule
- make_discoveryrule
- make_gpg_key
- make_content_credential
- make_location
- make_model
- make_partition_table
- make_product
- make_product_with_credentials
- make_product_wait
- make_proxy
- make_repository
- make_repository_with_credentials
- make_role
- make_filter
- make_scap_policy
- make_subnet
- make_sync_plan
- make_host
- make_fake_host
- make_host_collection
- make_job_invocation
- make_job_template
- make_user
- make_usergroup
- make_usergroup_external
- make_ldap_auth_source
- make_compute_resource
- make_org
- make_org_with_credentials
- make_realm
- make_report_template
- make_os
- make_scapcontent
- make_domain
- make_hostgroup
- make_medium
- make_environment
- make_lifecycle_environment
- make_tailoringfile
- make_template
- make_template_input
- make_virt_who_config
- activationkey_add_subscription_to_repo
- setup_org_for_a_custom_repo
- _setup_org_for_a_rh_repo
- setup_org_for_a_rh_repo
- configure_env_for_provision
- publish_puppet_module
- setup_virtual_machine
- _get_capsule_vm_distro_repos
- add_role_permissions
- setup_cdn_and_custom_repositories
- setup_cdn_and_custom_repos_content
- vm_setup_ssh_config
- vm_upload_ssh_key
- virt_who_hypervisor_config
- make_http_proxy
- Module Contents
robottelo.cli.file
robottelo.cli.filter
robottelo.cli.globalparam
robottelo.cli.gpgkey
robottelo.cli.hammer
robottelo.cli.host
- Module Contents
- Classes
- Host
- command_base
- ansible_roles_play
- enc_dump
- errata_apply
- errata_info
- errata_list
- facts
- package_install
- package_list
- package_remove
- package_upgrade
- package_upgrade_all
- package_group_install
- package_group_remove
- reboot
- reports
- start
- status
- stop
- subscription_register
- subscription_unregister
- subscription_attach
- subscription_remove
- subscription_auto_attach
- sc_params
- HostInterface
- Host
- Classes
- Module Contents
robottelo.cli.hostcollection
robottelo.cli.hostgroup
robottelo.cli.http_proxy
robottelo.cli.job_invocation
robottelo.cli.job_template
robottelo.cli.ldapauthsource
robottelo.cli.lifecycleenvironment
robottelo.cli.location
- Module Contents
- Classes
- Location
- command_base
- add_compute_resource
- add_domain
- add_environment
- add_hostgroup
- add_medium
- add_organization
- add_provisioning_template
- add_smart_proxy
- add_subnet
- add_user
- remove_compute_resource
- remove_domain
- remove_environment
- remove_hostgroup
- remove_medium
- remove_organization
- remove_provisioning_template
- remove_smart_proxy
- remove_subnet
- remove_user
- Location
- Classes
- Module Contents
robottelo.cli.medium
robottelo.cli.model
robottelo.cli.module_stream
robottelo.cli.operatingsys
robottelo.cli.org
- Module Contents
- Classes
- Org
- command_base
- add_compute_resource
- remove_compute_resource
- add_domain
- remove_domain
- add_environment
- remove_environment
- add_hostgroup
- remove_hostgroup
- add_location
- remove_location
- add_medium
- remove_medium
- add_provisioning_template
- remove_provisioning_template
- add_smart_proxy
- remove_smart_proxy
- add_subnet
- remove_subnet
- add_user
- remove_user
- Org
- Classes
- Module Contents
robottelo.cli.ostreebranch
robottelo.cli.package
robottelo.cli.partitiontable
robottelo.cli.product
robottelo.cli.proxy
robottelo.cli.puppet
robottelo.cli.puppetmodule
robottelo.cli.realm
robottelo.cli.recurring_logic
robottelo.cli.report
robottelo.cli.report_template
robottelo.cli.repository
robottelo.cli.repository_set
robottelo.cli.role
robottelo.cli.scap_policy
robottelo.cli.scap_tailoring_files
robottelo.cli.scapcontent
robottelo.cli.scparams
robottelo.cli.settings
robottelo.cli.srpm
robottelo.cli.subnet
robottelo.cli.subscription
robottelo.cli.syncplan
robottelo.cli.task
robottelo.cli.template
robottelo.cli.template_input
robottelo.cli.template_sync
robottelo.cli.user
robottelo.cli.usergroup
robottelo.cli.virt_who_config
- Submodules
robottelo.config
- Submodules
robottelo.config.base
- Module Contents
- Classes
- Functions
- Attributes
- LOGGER
- SETTINGS_FILE_NAME
- ImproperlyConfigured
- get_project_root
- INIReader
- FeatureSettings
- ServerSettings
- BrokerSettings
- BugzillaSettings
- CapsuleSettings
- CertsSettings
- ClientsSettings
- ContainerRepositorySettings
- DistroSettings
- DockerSettings
- AzureRMSettings
- EC2Settings
- FakeManifestSettings
- GCESettings
- RHSSOSettings
- LDAPSettings
- LDAPIPASettings
- OpenLDAPSettings
- LibvirtHostSettings
- FakeCapsuleSettings
- RHEVSettings
- VmWareSettings
- DiscoveryISOSettings
- OscapSettings
- OSPSettings
- PerformanceSettings
- SSHClientSettings
- VlanNetworkSettings
- UpgradeSettings
- SharedFunctionSettings
- VirtWhoSettings
- ReportPortalSettings
- Settings
- HttpProxySettings
- Module Contents
robottelo.config.casts
robottelo.config.facade
- Module Contents
- Classes
- Attributes
- logger
- WRAPPER_EXCEPTIONS
- SettingsNodeWrapper
- SettingsFacade
- _cache
- _configs
- set_configs
- _from_cache
- _add_to_cache
- _cached_function
- __all_features
- __server_get_credentials
- __server_get_url
- __server_get_pub_url
- __server_get_cert_rpm_url
- __server_version
- __server_get_hostname
- __capsule_hostname
- __ssh_client_command_timeout
- __ssh_client_connection_timeout
- _robottelo_verbosity
- _fake_capsules_port_range
- _dispatch_computed_value
- _dispatch_robottelo_value
- _dispatch_repos_value
- _get_from_configs
- get
- __dir__
- Module Contents
robottelo.config.validators
robottelo.config.virtwho
- Package Contents
- Classes
- Functions
- Attributes
- dynaconf_validators
- ImproperlyConfigured
- LegacySettings
- SettingsFacade
- _cache
- _configs
- set_configs
- _from_cache
- _add_to_cache
- _cached_function
- __all_features
- __server_get_credentials
- __server_get_url
- __server_get_pub_url
- __server_get_cert_rpm_url
- __server_version
- __server_get_hostname
- __capsule_hostname
- __ssh_client_command_timeout
- __ssh_client_connection_timeout
- _robottelo_verbosity
- _fake_capsules_port_range
- _dispatch_computed_value
- _dispatch_robottelo_value
- _dispatch_repos_value
- _get_from_configs
- get
- __dir__
- SettingsNodeWrapper
- logger
- legacy_settings
- dynaconf_settings
- settings_proxy
- settings
- setting_is_set
- Submodules
robottelo.constants
- Submodules
robottelo.constants.repos
- Module Contents
- REPOS_URL
- CUSTOM_FILE_REPO
- CUSTOM_KICKSTART_REPO
- CUSTOM_RPM_REPO
- CUSTOM_RPM_SHA_512
- CUSTOM_MODULE_STREAM_REPO_1
- CUSTOM_MODULE_STREAM_REPO_2
- CUSTOM_SWID_TAG_REPO
- FAKE_0_YUM_REPO
- FAKE_1_YUM_REPO
- FAKE_2_YUM_REPO
- FAKE_3_YUM_REPO
- FAKE_4_YUM_REPO
- FAKE_5_YUM_REPO
- FAKE_6_YUM_REPO
- FAKE_7_YUM_REPO
- FAKE_8_YUM_REPO
- FAKE_9_YUM_REPO
- FAKE_10_YUM_REPO
- FAKE_11_YUM_REPO
- FAKE_YUM_DRPM_REPO
- FAKE_YUM_SRPM_REPO
- FAKE_YUM_SRPM_DUPLICATE_REPO
- FAKE_YUM_MIXED_REPO
- FAKE_YUM_MD5_REPO
- CUSTOM_PUPPET_REPO
- FAKE_0_PUPPET_REPO
- FAKE_1_PUPPET_REPO
- FAKE_2_PUPPET_REPO
- FAKE_3_PUPPET_REPO
- FAKE_4_PUPPET_REPO
- FAKE_5_PUPPET_REPO
- FAKE_6_PUPPET_REPO
- FAKE_7_PUPPET_REPO
- FAKE_8_PUPPET_REPO
- FEDORA26_OSTREE_REPO
- FEDORA27_OSTREE_REPO
- OSTREE_REPO
- REPO_DISCOVERY_URL
- FAKE_0_INC_UPD_URL
- FAKE_PULP_REMOTE_FILEREPO
- FAKE_0_YUM_REPO_STRING_BASED_VERSIONS
- Module Contents
- Package Contents
- LOCALES
- DISTRO_RHEL6
- DISTRO_RHEL7
- DISTRO_RHEL8
- DISTRO_SLES11
- DISTRO_SLES12
- RHEL_6_MAJOR_VERSION
- RHEL_7_MAJOR_VERSION
- RHEL_8_MAJOR_VERSION
- DISTRO_DEFAULT
- DISTROS_SUPPORTED
- DISTROS_MAJOR_VERSION
- MAJOR_VERSION_DISTRO
- BROKER_DEPLOY_WORKFLOW
- BROKER_RHEL77
- INTERFACE_API
- INTERFACE_CLI
- FOREMAN_PROVIDERS
- EC2_REGION_CA_CENTRAL_1
- CONTENT_CREDENTIALS_TYPES
- VIRT_WHO_HYPERVISOR_TYPES
- LIBVIRT_RESOURCE_URL
- RHEV_CR
- AWS_EC2_FLAVOR_T2_MICRO
- COMPUTE_PROFILE_LARGE
- COMPUTE_PROFILE_SMALL
- _bcds
- _abcfs
- _abcs
- _zones_combo
- VALID_GCE_ZONES
- LATEST_RHEL7_GCE_IMG_UUID
- GCE_MACHINE_TYPE_DEFAULT
- GCE_NETWORK_DEFAULT
- GCE_EXTERNAL_IP_DEFAULT
- AZURERM_VALID_REGIONS
- AZURERM_RHEL7_FT_IMG_URN
- AZURERM_RHEL7_UD_IMG_URN
- AZURERM_RHEL7_FT_BYOS_IMG_URN
- AZURERM_RHEL7_FT_CUSTOM_IMG_URN
- AZURERM_RHEL7_FT_GALLERY_IMG_URN
- AZURERM_RG_DEFAULT
- AZURERM_PLATFORM_DEFAULT
- AZURERM_VM_SIZE_DEFAULT
- AZURERM_PREMIUM_OS_Disk
- AZURERM_FILE_URI
- HTML_TAGS
- OPERATING_SYSTEMS
- TEMPLATE_TYPES
- RESOURCE_DEFAULT
- OS_TEMPLATE_DATA_FILE
- DOMAIN
- PARTITION_SCRIPT_DATA_FILE
- SNIPPET_DATA_FILE
- SNIPPET_URL
- INSTALL_MEDIUM_URL
- VALID_GPG_KEY_FILE
- ZOO_CUSTOM_GPG_KEY
- VALID_GPG_KEY_BETA_FILE
- KEY_CLOAK_CLI
- RPM_TO_UPLOAD
- SRPM_TO_UPLOAD
- ENVIRONMENT
- NOT_IMPLEMENTED
- SYNC_INTERVAL
- REPO_TYPE
- DOWNLOAD_POLICIES
- CHECKSUM_TYPE
- HASH_TYPE
- REPO_TAB
- PRDS
- REPOSET
- NO_REPOS_AVAILABLE
- SM_OVERALL_STATUS
- REPOS
- DISTRO_REPOS
- RHVA_REPO_TREE
- SAT6_TOOLS_TREE
- ATOMIC_HOST_TREE
- DEFAULT_ORG
- DEFAULT_LOC
- DEFAULT_CV
- DEFAULT_TEMPLATE
- DEFAULT_PXE_TEMPLATE
- DEFAULT_ATOMIC_TEMPLATE
- DEFAULT_PTABLE
- DEFAULT_SUBSCRIPTION_NAME
- DEFAULT_ARCHITECTURE
- DEFAULT_RELEASE_VERSION
- DEFAULT_ROLE
- LANGUAGES
- SATELLITE_SUBSCRIPTION_NAME
- SATELLITE_FIREWALL_SERVICE_NAME
- VDC_SUBSCRIPTION_NAME
- TIMEZONES
- FILTER_CONTENT_TYPE
- FILTER_TYPE
- FILTER_ERRATA_TYPE
- FILTER_ERRATA_DATE
- REPORT_TEMPLATE_FILE
- REP_TEM_APPLIED_ERRATA_INPUT
- CONTAINER_REGISTRY_HUB
- CONTAINER_UPSTREAM_NAME
- CONTAINER_RH_REGISTRY_UPSTREAM_NAME
- CUSTOM_LOCAL_FOLDER
- CUSTOM_LOCAL_FILE
- CUSTOM_FILE_REPO_FILES_COUNT
- CUSTOM_RPM_SHA_512_FEED_COUNT
- CUSTOM_REPODATA_PATH
- CERT_PATH
- FAKE_0_YUM_REPO_PACKAGES_COUNT
- FAKE_0_INC_UPD_ERRATA
- FAKE_0_INC_UPD_OLD_PACKAGE
- FAKE_0_INC_UPD_NEW_PACKAGE
- FAKE_0_INC_UPD_OLD_UPDATEFILE
- FAKE_0_INC_UPD_NEW_UPDATEFILE
- INVALID_URL
- FAKE_0_CUSTOM_PACKAGE
- FAKE_0_CUSTOM_PACKAGE_NAME
- FAKE_1_CUSTOM_PACKAGE
- FAKE_1_CUSTOM_PACKAGE_NAME
- FAKE_2_CUSTOM_PACKAGE
- FAKE_2_CUSTOM_PACKAGE_NAME
- FAKE_3_CUSTOM_PACKAGE
- FAKE_3_CUSTOM_PACKAGE_NAME
- FAKE_4_CUSTOM_PACKAGE
- FAKE_4_CUSTOM_PACKAGE_NAME
- FAKE_5_CUSTOM_PACKAGE
- REAL_0_RH_PACKAGE
- REAL_RHEL7_0_0_PACKAGE
- REAL_RHEL7_0_0_PACKAGE_NAME
- REAL_RHEL7_0_1_PACKAGE
- REAL_RHEL7_0_1_PACKAGE_FILENAME
- REAL_RHEL7_0_2_PACKAGE_NAME
- REAL_RHEL7_0_2_PACKAGE_FILENAME
- FAKE_0_CUSTOM_PACKAGE_GROUP_NAME
- FAKE_3_YUM_OUTDATED_PACKAGES
- FAKE_9_YUM_OUTDATED_PACKAGES
- FAKE_9_YUM_UPDATED_PACKAGES
- FAKE_0_MODULAR_ERRATA_ID
- FAKE_0_ERRATA_ID
- FAKE_1_ERRATA_ID
- FAKE_2_ERRATA_ID
- FAKE_3_ERRATA_ID
- FAKE_4_ERRATA_ID
- FAKE_5_ERRATA_ID
- REAL_0_ERRATA_ID
- REAL_1_ERRATA_ID
- REAL_2_ERRATA_ID
- REAL_4_ERRATA_ID
- REAL_4_ERRATA_CVES
- REAL_RHEL7_0_ERRATA_ID
- REAL_RHEL7_1_ERRATA_ID
- FAKE_0_YUM_ERRATUM_COUNT
- FAKE_1_YUM_ERRATUM_COUNT
- FAKE_1_YUM_REPOS_COUNT
- FAKE_2_YUM_ERRATUM_COUNT
- FAKE_3_YUM_ERRATUM_COUNT
- FAKE_3_YUM_REPOS_COUNT
- FAKE_6_YUM_ERRATUM_COUNT
- FAKE_9_YUM_ERRATUM_COUNT
- FAKE_9_YUM_ERRATUM
- FAKE_9_YUM_SECURITY_ERRATUM
- FAKE_9_YUM_SECURITY_ERRATUM_COUNT
- FAKE_10_YUM_BUGFIX_ERRATUM
- FAKE_10_YUM_BUGFIX_ERRATUM_COUNT
- FAKE_11_YUM_ENHANCEMENT_ERRATUM
- FAKE_11_YUM_ENHANCEMENT_ERRATUM_COUNT
- PUPPET_MODULE_NTP_PUPPETLABS
- PUPPET_MODULE_CUSTOM_FILE_NAME
- PUPPET_MODULE_CUSTOM_NAME
- FAKE_0_CUSTOM_PACKAGE_GROUP
- FAKE_1_YUM_REPO_RPMS
- FAKE_0_PUPPET_MODULE
- FAKE_0_YUM_REPO_STRING_BASED_VERSIONS_COUNTS
- PULP_PUBLISHED_ISO_REPOS_PATH
- PULP_PUBLISHED_PUPPET_REPOS_PATH
- PULP_PUBLISHED_YUM_REPOS_PATH
- PERMISSIONS
- PERMISSIONS_UI
- ANY_CONTEXT
- SUBNET_IPAM_TYPES
- LDAP_SERVER_TYPE
- LDAP_ATTR
- OSCAP_PERIOD
- OSCAP_WEEKDAY
- OSCAP_DEFAULT_CONTENT
- OSCAP_PROFILE
- ROLES
- ROLES_UNLOCKED
- ROLES_LOCKED
- BOOKMARK_ENTITIES
- STRING_TYPES
- REAL_4_ERRATA_DETAILS
- TOOLS_ERRATA_DETAILS
- TOOLS_ERRATA_TABLE_DETAILS
- BACKUP_FILES
- HOT_BACKUP_FILES
- VMWARE_CONSTANTS
- HAMMER_CONFIG
- FOREMAN_TEMPLATE_IMPORT_URL
- FOREMAN_TEMPLATES_COMMUNITY_URL
- FOREMAN_TEMPLATE_TEST_TEMPLATE
- FOREMAN_TEMPLATE_ROOT_DIR
- DEFAULT_SYSPURPOSE_ATTRIBUTES
- OPEN_STATUSES
- CLOSED_STATUSES
- WONTFIX_RESOLUTIONS
- GROUP_MEMBERSHIP_MAPPER
- AUDIENCE_MAPPER
- RHSSO_NEW_USER
- RHSSO_USER_UPDATE
- RHSSO_NEW_GROUP
- RHSSO_RESET_PASSWORD
- FOREMAN_ANSIBLE_MODULES
- FAM_MODULE_PATH
- Submodules
robottelo.decorators
- Subpackages
robottelo.decorators.func_shared
- Submodules
robottelo.decorators.func_shared.base
robottelo.decorators.func_shared.file_storage
robottelo.decorators.func_shared.redis_storage
robottelo.decorators.func_shared.shared
- Module Contents
- Classes
- Functions
- Attributes
- logger
- _storage_handlers
- DEFAULT_STORAGE_HANDLER
- ENABLED
- NAMESPACE_SCOPE
- SHARE_DEFAULT_TIMEOUT
- DEFAULT_CALL_RETRIES
- _configured
- _NAMESPACE_SCOPE_KEY_TYPE
- _DEFAULT_CLASS_NAME_DEPTH
- _STATE_READY
- _STATE_FAILED
- _DATETIME_FORMAT
- _SERVER_CERT_MD5
- _set_configured
- _check_config
- enable_shared_function
- set_default_scope
- _get_default_scope
- _get_default_storage_handler
- SharedFunctionError
- SharedFunctionException
- _SharedFunction
- _get_kwargs_md5
- _get_scope_name
- _get_function_name
- _get_function_name_key
- shared
- Module Contents
- Package Contents
- Submodules
- Submodules
robottelo.decorators.func_locker
- Module Contents
- Functions
- Attributes
- logger
- TEMP_ROOT_DIR
- TEMP_FUNC_LOCK_DIR
- LOCK_DIR
- LOCK_DEFAULT_TIMEOUT
- LOCK_FILE_NAME_EXT
- LOCK_DEFAULT_SCOPE
- _DEFAULT_CLASS_NAME_DEPTH
- FunctionLockerError
- set_default_scope
- _get_default_scope
- get_temp_dir
- _get_temp_lock_function_dir
- _get_scope_path
- _get_function_name
- _get_function_name_lock_path
- _check_deadlock
- _write_content
- lock_function
- locking_function
- Module Contents
robottelo.decorators.host
- Package Contents
- Subpackages
robottelo.report_portal
robottelo.ui
robottelo.utils
- Submodules
robottelo.cleanup
robottelo.datafactory
- Module Contents
- Functions
- InvalidArgumentError
- filtered_datapoint
- parametrized
- generate_strings_list
- add_uppercase_char_into_string
- invalid_emails_list
- invalid_boolean_strings
- xdist_adapter
- invalid_id_list
- invalid_names_list
- valid_domain_names
- invalid_domain_names
- invalid_usernames_list
- invalid_values_list
- valid_data_list
- valid_docker_repository_names
- valid_emails_list
- valid_environments_list
- invalid_environments_list
- valid_hosts_list
- valid_hostgroups_list
- valid_labels_list
- valid_names_list
- valid_org_names_list
- valid_usernames_list
- valid_interfaces_list
- invalid_interfaces_list
- valid_http_credentials
- invalid_http_credentials
- invalid_docker_upstream_names
- valid_docker_upstream_names
- valid_url_list
- valid_cron_expressions
- Functions
- Module Contents
robottelo.errors
robottelo.helpers
- Module Contents
- Classes
- Functions
- Attributes
- LOGGER
- DataFileError
- HostInfoError
- ProvisioningCheckError
- InvalidArgumentError
- ProxyError
- DownloadFileError
- ServerFileDownloader
- download_server_file
- file_downloader
- get_server_software
- get_server_version
- get_host_info
- get_nailgun_config
- escape_search
- update_dictionary
- get_data_file
- read_data_file
- install_katello_ca
- remove_katello_ca
- md5_by_url
- add_remote_execution_ssh_key
- get_available_capsule_port
- default_url_on_new_port
- Storage
- get_func_name
- get_services_status
- form_repo_path
- create_repo
- repo_add_updateinfo
- extract_capsule_satellite_installer_command
- extract_ui_token
- get_web_session
- host_provisioning_check
- slugify_component
- download_gce_cert
- idgen
- Module Contents
robottelo.host_info
robottelo.hosts
- Module Contents
- Classes
- Functions
- Attributes
- logger
- setup_capsule
- ContentHostError
- ContentHost
- run
- subscribed
- nailgun_host
- subscribed
- ip_addr
- download_install_rpm
- enable_repo
- subscription_manager_list_repos
- subscription_manager_status
- subscription_manager_list
- create_custom_repos
- install_katello_agent
- install_katello_host_tools
- install_katello_ca
- install_capsule_katello_ca
- register_contenthost
- remove_katello_ca
- unregister
- get
- put
- configure_rhel_repo
- configure_puppet
- execute_foreman_scap_client
- configure_rhai_client
- unregister_insights
- set_infrastructure_type
- patch_os_release_version
- Capsule
- Satellite
- Module Contents
robottelo.libvirt_discovery
robottelo.log
robottelo.manifests
robottelo.products
- Module Contents
- Classes
- Functions
- Attributes
- REPO_TYPE_YUM
- REPO_TYPE_DOCKER
- REPO_TYPE_PUPPET
- REPO_TYPE_OSTREE
- DOWNLOAD_POLICY_ON_DEMAND
- DOWNLOAD_POLICY_IMMEDIATE
- DOWNLOAD_POLICY_BACKGROUND
- PRODUCT_KEY_RHEL
- PRODUCT_KEY_SAT_TOOLS
- PRODUCT_KEY_SAT_CAPSULE
- PRODUCT_KEY_VIRT_AGENTS
- PRODUCT_KEY_CLOUD_FORMS_TOOLS
- PRODUCT_KEY_ANSIBLE_ENGINE
- _server_distro
- RepositoryAlreadyDefinedError
- DistroNotSupportedError
- RepositoryDataNotFound
- OnlyOneOSRepositoryAllowed
- RepositoryAlreadyCreated
- ReposContentSetupWasNotPerformed
- get_server_distro
- BaseRepository
- YumRepository
- DockerRepository
- PuppetRepository
- OSTreeRepository
- GenericRHRepository
- RHELRepository
- SatelliteToolsRepository
- SatelliteCapsuleRepository
- VirtualizationAgentsRepository
- RHELCloudFormsTools
- RHELAnsibleEngineRepository
- RepositoryCollection
- _distro
- _org
- _items
- _repos_info
- _custom_product_info
- _os_repo
- _setup_content_data
- distro
- repos_info
- custom_product
- os_repo
- repos_data
- rh_repos
- custom_repos
- rh_repos_info
- custom_repos_info
- setup_content_data
- need_subscription
- organization
- add_item
- add_items
- __iter__
- setup
- setup_content_view
- setup_activation_key
- organization_has_manifest
- setup_content
- setup_virtual_machine
- Module Contents
robottelo.rh_cloud_utils
robottelo.rhsso_utils
- Module Contents
- Functions
- Attributes
- satellite
- rhsso_host
- realm
- rhsso_user
- rhsso_password
- run_command
- get_rhsso_client_id
- get_rhsso_user_details
- get_rhsso_groups_details
- upload_rhsso_entity
- create_mapper
- create_new_rhsso_user
- update_rhsso_user
- delete_rhsso_user
- create_group
- delete_rhsso_group
- update_client_configuration
- get_oidc_token_endpoint
- get_oidc_client_id
- get_oidc_authorization_endpoint
- get_two_factor_token_rh_sso_url
- open_pxssh_session
- set_the_redirect_uri
- Module Contents
robottelo.ssh
robottelo.system_facts
robottelo.upgrade_utility
robottelo.virtwho_utils
- Module Contents
- Functions
- Attributes
- VIRTWHO_SYSCONFIG
- virtwho
- VirtWhoError
- _parse_entry
- get_system
- get_guest_info
- runcmd
- register_system
- virtwho_cleanup
- get_virtwho_status
- get_configure_id
- get_configure_command
- get_configure_file
- get_configure_option
- _get_hypervisor_mapping
- deploy_validation
- deploy_configure_by_command
- deploy_configure_by_script
- restart_virtwho_service
- update_configure_option
- delete_configure_option
- add_configure_option
- hypervisor_json_create
- create_fake_hypervisor_content
- get_hypervisor_info
- virtwho_package_locked
- create_http_proxy
- Module Contents
robottelo.vm
- Module Contents
- Classes
- Attributes
- logger
- VirtualMachineError
- VirtualMachine
- allowed_distros
- subscribed
- domain
- hostname
- target_image
- create
- destroy
- download_install_rpm
- enable_repo
- subscription_manager_list_repos
- subscription_manager_status
- create_custom_repos
- install_katello_agent
- install_katello_host_tools
- install_katello_ca
- install_capsule_katello_ca
- register_contenthost
- remove_katello_ca
- remove_capsule_katello_ca
- unregister
- run
- get
- put
- configure_rhel_repo
- configure_puppet
- execute_foreman_scap_client
- configure_rhai_client
- set_infrastructure_type
- patch_os_release_version
- __enter__
- __exit__
- Module Contents
robottelo.vm_capsule
- Subpackages
- hidden
committing code_standards reviewing_PRs features/index autoapi/index
Want to contribute? Before submitting code, read through the committing guide and Robottelo code standards. Ready to start reviewing pull requests? We have a guide for that too! Finally, the API reference covers individual functions, classes, methods and modules.
Robottelo is compatible with Python 3.6+.
Bugs are listed on GitHub. If you think you’ve found a new issue, please do one of the following:
Open a new bug report on Github.
Join the #robottelo IRC channel on Freenode (irc.freenode.net).
You can generate the documentation for Robottelo as follows, so long as you have Sphinx and make installed:
$ cd docs
$ make html
You can generate a graph of Foreman entities and their dependencies, so long as you have graphviz installed:
$ make graph-entities
To check for code smells:
$ pre-commit install-hooks
$ pre-commit run --all-files
The design and development for this software is led by Og Maciel.