Location: Pulp SmashAPI Documentationpulp_smash.tests.platform.cli.test_content_sources

Tests for list/refresh/delete content sources.

class pulp_smash.tests.platform.cli.test_content_sources.RefreshAndDeleteContentSourcesTestCase(methodName='runTest')

Test whether pulp-admin client can refresh and delete content source.

This test case targets Pulp #1692`_ and Pulp Smash #141. The content sources documentation describes the CLI syntax. The test steps are as follows:

  1. Create configuration file of a content source.
  2. Check whether the content sources list is empty.
  3. Refresh all content sources. Verify no errors are reported.
  4. Refresh a specified content source. Verify no errors are reported.
  5. Remove the specified content source. Verify that the source is actually deleted.
classmethod setUpClass()

Create a content source.


Check if a content source can be deleted.


Check if content sources can be listed.


Refresh all content sources.


Refresh a specific content source.

pulp_smash.tests.platform.cli.test_content_sources.generate_content_source(server_config, name, **kwargs)

Generate a content source file and returns its remote path.

See Defining a Content Source for more information.

  • server_config – A pulp_smash.config.PulpSmashConfig object.
  • name – file name and content source id (string inside []).
  • kwargs – each item will be converted to content source properties where the key is the property name and the value its value.

the remote path of the created content source file.