-
Notifications
You must be signed in to change notification settings - Fork 9
Update test helpers to understand field keys and names #2450
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
src/org/labkey/test/components/ui/entities/EntityBulkInsertDialog.java
Outdated
Show resolved
Hide resolved
src/org/labkey/test/components/ui/entities/EntityInsertPanel.java
Outdated
Show resolved
Hide resolved
labkey-danield
approved these changes
May 23, 2025
# Conflicts: # src/org/labkey/test/util/TestDataGenerator.java
This was referenced May 29, 2025
This was referenced Jun 25, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Rationale
https://github.com/LabKey/kanban/issues/689
Field labels are an inconsistent way to define and reference data. We should encourage and enable tests to use field keys and field names instead.
This update allows data Maps to be keyed differently when extracted from various grid components for test validation. In addition to the existing label-keyed maps, there are now methods to key data by
FieldKeyor by name (unencoded FieldKey).When looking for specific columns, the grid components will accept encoded or unencoded field keys in addition to labels. This allows the many existing tests that use field labels to continue to do so while allowing new tests to be more precise.
Some components that already found columns by encoded FieldKey (bulk update forms and details tables) have been updated to find
FieldKeyobjects orStrings.Strings are assumed to be field names which the component will encode. This allows tests to not have to bother with fieldKey encoding except when absolutely necessary (e.g. parent or source lookups). Note: I would like to implement a similar change to the grids but that can waitRelated Pull Requests
Changes
FieldKeyto extendCharSequenceTestDataGeneratorandTestDataUtils