pulp_2_tests.tests.rpm.api_v2.test_no_op_publish¶
Location: Pulp 2 Tests → Tests → pulp_2_tests.tests.rpm.api_v2.test_no_op_publish
Test Pulp’s handling of no-op publishes.
As of version 2.9, Pulp has the ability to perform no-op publishes, instead of the more typical full publish. A no-op publish is one in which no files are changed, including metadata files. No-op publishes occur when all of the components — including the repository, distributor and override config — are unchanged.
Tests for this feature include the following:
- Publish a repository twice. (See
PubTwiceTestCase.) - Publish a repository, change it, and publish it again. (See
ChangeRepoTestCase.) - Publish a repository twice, with an override config the second time. (See
pulp_2_tests.tests.rpm.api_v2.test_export.ExportDistributorTestCase.) - Publish a repository twice, with an override config both times. (See
PubTwiceWithOverrideTestCase.)
For more information, see:
-
class
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.BaseTestCase(*args, **kwargs)¶ Bases:
pulp_smash.pulp2.utils.BaseAPITestCaseProvide common behaviour for the test cases in this module.
-
classmethod
setUpClass()¶ Create a repository with a distributor, and populate it.
In addition, create several variables for use by the test methods.
-
test_first_publish()¶ Assert the first publish is a full publish.
-
classmethod
-
class
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.ChangeRepoTestCase(*args, **kwargs)¶ Bases:
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.BaseTestCasePublish a repository, change it, and publish it again.
-
classmethod
setUpClass()¶ Publish a repository, change it, and publish it again.
-
test_second_publish_repomd()¶ Assert the two publishes produce identical
repomd.xmlfiles.
-
test_second_publish_tasks()¶ Assert the second publish’s last task reports a no-op publish.
-
classmethod
-
class
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.NoOpPublishMixin¶ Bases:
objectProvide tests for the no-op publish test cases in this module.
-
test_second_publish_repomd()¶ Assert the two publishes produce identical
repomd.xmlfiles.
-
test_second_publish_tasks()¶ Assert the second publish’s last task reports a no-op publish.
-
-
class
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.PubTwiceTestCase(*args, **kwargs)¶ Bases:
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.BaseTestCase,pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.NoOpPublishMixinPublish a repository twice.
-
classmethod
setUpClass()¶ Publish a repository twice.
-
classmethod
-
class
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.PubTwiceWithOverrideTestCase(*args, **kwargs)¶ Bases:
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.BaseTestCase,pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.NoOpPublishMixinPublish a repository twice, with an override config both times.
-
classmethod
setUpClass()¶ Publish a repository twice, with an override config both times.
-
classmethod
-
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.get_repomd_xml_path(distributor_rel_url)¶ Construct the path to a repository’s
repomd.xmlfile.Parameters: distributor_rel_url – A distributor’s relative_urloption.Returns: An string path to a repomd.xmlfile.
-
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.setUpModule()¶ Possibly skip the tests in this module. Create and sync an RPM repo.
Skip this module of tests if Pulp is older than version 2.9. (See Pulp #1724.) Then create an RPM repository with a feed and sync it. Test cases may copy data from this repository but should not change it.
-
pulp_2_tests.tests.rpm.api_v2.test_no_op_publish.tearDownModule()¶ Delete the repository created by
setUpModule().