def test_CRUD_dicom_store(test_dataset, capsys): dicom_stores.create_dicom_store( service_account_json, project_id, cloud_region, dataset_id, dicom_store_id) dicom_stores.get_dicom_store( service_account_json, project_id, cloud_region, dataset_id, dicom_store_id) dicom_stores.list_dicom_stores( service_account_json, project_id, cloud_region, dataset_id) dicom_stores.delete_dicom_store( service_account_json, project_id, cloud_region, dataset_id, dicom_store_id) out, _ = capsys.readouterr() # Check that create/get/list/delete worked assert 'Created DICOM store' in out assert 'Name' in out assert 'dicomStores' in out assert 'Deleted DICOM store' in out
def test_CRUD_dicom_store(test_dataset, crud_dicom_store_id, capsys): dicom_stores.create_dicom_store(project_id, cloud_region, dataset_id, crud_dicom_store_id) dicom_stores.get_dicom_store(project_id, cloud_region, dataset_id, crud_dicom_store_id) dicom_stores.list_dicom_stores(project_id, cloud_region, dataset_id) dicom_stores.delete_dicom_store(project_id, cloud_region, dataset_id, crud_dicom_store_id) out, _ = capsys.readouterr() # Check that create/get/list/delete worked assert "Created DICOM store" in out assert "name" in out assert "dicomStores" in out assert "Deleted DICOM store" in out
def test_CRUD_dicom_store(test_dataset, crud_dicom_store_id, capsys): @backoff.on_exception(backoff.expo, HttpError, max_time=60) def create(): dicom_stores.create_dicom_store(project_id, location, dataset_id, crud_dicom_store_id) create() dicom_stores.get_dicom_store(project_id, location, dataset_id, crud_dicom_store_id) dicom_stores.list_dicom_stores(project_id, location, dataset_id) dicom_stores.delete_dicom_store(project_id, location, dataset_id, crud_dicom_store_id) out, _ = capsys.readouterr() # Check that create/get/list/delete worked assert "Created DICOM store" in out assert "name" in out assert "dicomStores" in out assert "Deleted DICOM store" in out