Location: Pulp SmashAPI Documentationpulp_smash.tests.rpm.api_v2.test_iso_crud

Test CRUD for ISO RPM repositories.

class pulp_smash.tests.rpm.api_v2.test_iso_crud.AddImporterDistributorTestCase(methodName='runTest')

Add an importer and a distributor to an existing untyped repository.


classmethod setUpClass()

Create a repository and add an importer and distributor to it.

Do the following:

  1. Create a repository.
  2. Read the repository’s importers and distributors.
  3. Add an importer and distributor to the repo.
  4. Re-read the repository’s importers and distributors.

Check the HTTP status code for adding a distributor.


Check the HTTP status code for adding an importer.


Verify the repository ends up with one importer and distributor.


Verify the repository has no importer or distributors initially.

class pulp_smash.tests.rpm.api_v2.test_iso_crud.CreateTestCase(methodName='runTest')

Create an ISO RPM repo with an importer and distributor.

classmethod setUpClass()

Create an ISO RPM repo with an importer and distributor.


Assert the created repository has the requested attributes.


Assert the response’s Location header is correct.

The Location may be either an absolute or relative URL. See pulp_smash.tests.platform.api_v2.test_repository.CreateSuccessTestCase.test_location_header().


Assert the response has an HTTP 201 status code.

class pulp_smash.tests.rpm.api_v2.test_iso_crud.PulpManifestTestCase(methodName='runTest')

Ensure ISO repo properly handles PULP_MANIFEST information.

static parse_pulp_manifest(feed_url)

Parse PULP_MANIFEST information from feed_url/PULP_MANIFEST.

Parameters:feed_url – The URL for the file feed. It will be joined with /PULP_MANIFEST in order to find the PULP_MANIFEST file.
Returns:A list of dicts mapping each PULP_MANIFEST row. The dict contains the keys name, checksum and size which represent the PULP_MANIFEST data.

Create and sync a ISO repo from an invalid file feed.

Assert that the sync fails with the information that some units were not available.


Create and sync a ISO repo from a file feed.

Assert that the number of units synced is the same as PULP_MANIFEST lists.

class pulp_smash.tests.rpm.api_v2.test_iso_crud.ReadUpdateDeleteTestCase(methodName='runTest')

Establish that we can interact with typed repositories as expected.

classmethod setUpClass()

Create three repositories and read, update and delete them.


Assert that the “read” call returns correct attributes.


Assert each read w/distributors contains info about distributors.


Assert each read with importers contains info about importers.


Assert each response has a correct HTTP status code.