Skip to content

Conversation

@couthcommander
Copy link
Contributor

Fix for #484, adding a new variable to "redcapUserStructure"

include data_access_group_label in user structure
data_access_group has been around for a while, and likely doesn't need the version check
@obregos
Copy link
Collaborator

obregos commented Dec 3, 2025

2 Failed Tests:

Failure (test-361-userStructureVersion.R:28:3): Prep user import pre 14.4.0 fails if given email_logging
Expected `prepUserImportData(User, rcon = old_rcon)` to run without any errors.
i Actually got a <simpleError> with text:
  1 assertions failed:
   * Variable 'primary_fields': Must be a subset of
   * {'username','email','firstname','lastname','expiration','data_access_group_id','design','alerts','user_rights','data_access_groups','reports','stats_and_charts','manage_survey_participants','calendar','data_import_tool','data_comparison_tool','logging','email_logging','file_repository','data_quality_create','data_quality_execute','api_export','api_import','api_modules','mobile_app','mobile_app_download_data','record_create','record_rename','record_delete','lock_records_all_forms','lock_records','lock_records_customization','mycap_participants','random_setup','random_dashboard','random_perform','forms','forms_export','data_export'},
   * but has additional elements {'data_access_group','data_access_group_label'}.

Failure (test-361-userStructureVersion.R:44:3): Prep user import pre 14.0.3 fails if given api_modules
Expected `prepUserImportData(User, rcon = old_rcon)` to run without any errors.
i Actually got a <simpleError> with text:
  1 assertions failed:
   * Variable 'primary_fields': Must be a subset of
   * {'username','email','firstname','lastname','expiration','data_access_group_id','design','alerts','user_rights','data_access_groups','reports','stats_and_charts','manage_survey_participants','calendar','data_import_tool','data_comparison_tool','logging','file_repository','data_quality_create','data_quality_execute','api_export','api_import','api_modules','mobile_app','mobile_app_download_data','record_create','record_rename','record_delete','lock_records_all_forms','lock_records','lock_records_customization','mycap_participants','random_setup','random_dashboard','random_perform','forms','forms_export','data_export'},
   * but has additional elements {'data_access_group','data_access_group_label'}.

[ FAIL 2 | WARN 0 | SKIP 13 | PASS 2047 ]

add a few missing entries
update user structure tests to better reflect version changes
Copy link
Collaborator

@obregos obregos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[ FAIL 0 | WARN 0 | SKIP 13 | PASS 2052 ]

@couthcommander couthcommander merged commit 84bd62d into main Dec 4, 2025
7 checks passed
@spgarbet spgarbet deleted the issue-484-userdaglabel branch January 6, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants