-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DD-1493: Add command for dataverse role assignment #53
DD-1493: Add command for dataverse role assignment #53
Conversation
Needs refactoring, it is using the batchprocessor, but with dataverses and aliases instead of datasets and pids, which makes the code confusing. |
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #53 +/- ##
==========================================
- Coverage 41.66% 41.42% -0.25%
==========================================
Files 18 18
Lines 828 857 +29
==========================================
+ Hits 345 355 +10
- Misses 483 502 +19 ☔ View full report in Codecov by Sentry. |
…ed members of the dataverse_api
…ommandline interface
…nstead of input param
Fixes DD-1493
Description of changes
Added dv-dataverse-role-assignment, similar to that for datasets, but needs aliases instead of PIDs
How to test
Assuming you have an assigment like the following; a mail domain for
exampleorg
and a dataverse with the aliasdans
:poetry run dv-dataverse-role-assignment list dans
Should not list that assignment.
poetry run dv-dataverse-role-assignment add '&maildomain/exampleorg=dsContributor' dans
Should be stating it was added
poetry run dv-dataverse-role-assignment add '&maildomain/exampleorg=dsContributor' dans
Should be stating it wasn't needed, because it was already assigned.
poetry run dv-dataverse-role-assignment list dans
Should list that assignment.
poetry run dv-dataverse-role-assignment remove '&maildomain/exampleorg=dsContributor' dans
Should be stating it was removed
poetry run dv-dataverse-role-assignment remove '&maildomain/exampleorg=dsContributor' dans
Should be stating it wasn't needed, because it was not assigned.
poetry run dv-dataverse-role-assignment list dans
Should not list that assignment.
The add and remove commands should be run with a file containing several aliases of dataverses. Producing similar results, but then for all the aliases.
Because of the refactoring it would be wise to also test
dv-dataverse-root-collect-permission-overview
anddv-dataverse-root-collect-storage-usage
.Related PRs
(Add links)
*#52
Notify
@DANS-KNAW/core-systems