Task #8302
Updated by pulpbot over 2 years ago
**Ticket moved to GitHub**: "pulp/pulp_rpm/2266":https://github.com/pulp/pulp_rpm/issues/2266 ---- ~~~ (pulp) [vagrant@pulp3-source-centos7 pulp_rpm]$ pytest --verbose --color=yes pulp_rpm/tests/functional/api/test_upload.py ============================================================================================================ test session starts ============================================================================================================= platform linux -- Python 3.6.8, pytest-6.2.2, py-1.10.0, pluggy-0.13.1 -- /usr/local/lib/pulp/bin/python3.6 cachedir: .pytest_cache rootdir: /home/vagrant/devel/pulp_rpm collected 2 items pulp_rpm/tests/functional/api/test_upload.py::ContentUnitTestCase::test_single_request_unit_and_duplicate_unit FAILED [ 50%] pulp_rpm/tests/functional/api/test_upload.py::ContentUnitTestCase::test_upload_non_ascii PASSED [100%] ================================================================================================================== FAILURES ================================================================================================================== ______________________________________________________________________________________ ContentUnitTestCase.test_single_request_unit_and_duplicate_unit _______________________________________________________________________________________ self = <pulp_rpm.tests.functional.api.test_upload.ContentUnitTestCase testMethod=test_single_request_unit_and_duplicate_unit> def test_single_request_unit_and_duplicate_unit(self): """Test single request upload unit. 1. Upload a unit 2. Attempt to upload same unit """ # Single unit upload upload = self.do_test(self.file_to_use) > content = monitor_task(upload.task).created_resources[0] pulp_rpm/tests/functional/api/test_upload.py:55: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ task_href = '/pulp/api/v3/tasks/68cff906-5e87-469e-a184-effbc9d2352b/' def monitor_task(task_href): """Polls the Task API until the task is in a completed state. Prints the task details and a success or failure message. Exits on failure. Args: task_href(str): The href of the task to monitor Returns: list[str]: List of hrefs that identify resource created by the task """ completed = ["completed", "failed", "canceled"] task = tasks.read(task_href) while task.state not in completed: sleep(SLEEP_TIME) task = tasks.read(task_href) if task.state != "completed": > raise PulpTaskError(task=task) E pulp_smash.pulp3.bindings.PulpTaskError: (PulpTaskError(...), "Pulp task failed ({'non_field_errors': [ErrorDetail(string='There is already a package with: arch=noarch, checksum_type=sha256, epoch=0, name=kangaroo, pkgId=865a4 c89485bdd9723a3c407280c141e9202f024e7db38cba3d097c3f256b2fd, release=1, version=0.3.', code='invalid')]})") /usr/local/lib/pulp/lib64/python3.6/site-packages/pulp_smash/pulp3/bindings.py:72: PulpTaskError ~~~