Feature/attribute identifier respect key #735
Merged
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.
Before submission, please check that ...
you updated necessary documentation within retest/docs.Description
For the return of one-click-maintenance (more details in #726), the GlobalChangeSetApplier
uses the
AttributeDifference#identifier()
to find equal differences, sinceAttributeDifference#equals
per definition cannot be used since it would check the warnings too.However, the identifier currently only takes the
expected
andactual
values into account, ignoring thekey
attribute. That means, following differences are considered equal, although differing in keys:This causes review to accept these attributes with a single click (which, currently, is not the expected behavior, as that could group completely different differences).
Technically, the above example is the same difference, because in the report the differences could be grouped to
border-color: expected=rgba(0, 0, 0, 0.26), actual=rgba(0, 0, 0, 0.32)
, but since we cannot implement grouping (technically), this is unwanted behavior.State of this PR
I do not know what the intentions were to exclude the key from the identifier (since I could not search through the history of the different repositories), but a quick usage search indicates that this should not have any breaking side-effects.