chore: update dependency com_github_google_go_cmp to v0.5.8 #3427
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.
This PR contains the following updates:
v0.0.0
->v0.5.8
Release Notes
google/go-cmp
v0.5.8
Compare Source
Reporter changes:
Dependency changes:
xerrors
dependencyv0.5.7
Compare Source
Reporter changes:
Code cleanup changes:
v0.5.6
Compare Source
Reporter changes:
Minor documentation changes:
v0.5.5
Compare Source
v0.5.4
Compare Source
Bug fixes:
(#247) Fix non-determinism in diffing algorithm
(#248) Impose verbosity limit when formatting map keys
v0.5.3
Compare Source
Minor documentation changes:
(#236) Fix license headers
(#205) Add an example for IgnoreFields
(#237) Fix Diff documentation
v0.5.2
Compare Source
Minor documentation changes:
(#234) Suggest use of cmpopts.EquateErrors
(#231) Fix Diff documentation
v0.5.1
Compare Source
Minor reporter changes:
String
orError
methds.Minor documentation changes:
IgnoreUnexported
andIgnoreFields
to be more specific.v0.5.0
Compare Source
The most notable changes in this release are improvements to the reporter output (i.e., the implementation that produces output for
Diff
). The changes seek to improve the signal-to-noise ratio such that differences of interest to the user are emphasized, while information that is less relevant are de-emphasized.The reporter largely consists of a set of heuristics to determine what would be the best way to format the difference in the common case. If the output seems sub-par, please file an issue. The reports are highly valuable in improving its output (e.g., #195, #194, #202, #185).
Reporter changes:
strings.Join({...}, "\n")
syntax to show diffs between lines within a string. While this representation is unambiguous, the need to escape every line made the output visually distracting. Now, we add a new syntax where multiple lines are represented by a literal syntax using"""
as delimiters. When possible, this syntax is preferred if it can unambiguously represent the difference.cmp.Comparer(bytes.Equal)
so that large byte slices are compared using an efficient implementation. Previously, this would prevent the reporter from being able to use specialized logic to show the per-element difference between these two slices if they were different, but now it is able to.String
method, using fully qualified type names, or some combination of the above.1776240
) Forcibly export fields for use by the reporter. This allows the reporter to use theString
orError
method (if available) to format values within unexported fields. This occurs regardless of whether anycmp.Exporter
orcmp.AllowUnexported
options are used or not.Feature changes:
cmpopts.IgnoreFields
option now accepts unexported field names. Unlike exported fields, unexported field must be explicitly specified as they do not respect forwarding due to struct embedding.Comparer changes:
cmp
package is intended for use primarily within tests where the expected outcome is generally equality. Previously, even if the result is equal,cmp.Diff
would construct an expensive diff tree only to discard the result since the values are equal. Now, optimize for the common case by first checking whether the values are equal first, and only construct a diff if they are not.unsafe
, it requires that the parent struct be addressable. In Go, a struct field is only addressable if and only if the parent struct is addressable. To avoid leaking this internal implementation detail, we shallow copy the result to remove properties of addressability.v0.4.1
Compare Source
Minor reporter changes:
Minor documentation changes:
v0.4.0
Compare Source
Added features:
cmp.Exporter
option provides finer-grained control over exactly what types to permit unexported field access on.cmpopts.EquateApproxTime
provides the ability to compare timestamps with looser precision.cmpopts.EquateErrors
provides the ability to compare error values using the newerrors.Is
semantics from Go 1.13.Bug fixes:
unsafe.Pointer
has been fixed to comply with stricter pointer rules for Go 1.14.v0.3.1
Compare Source
Minor reporter fixes:
String
method when formatting map keys.v0.3.0
Compare Source
Added features:
_
field is always ignored when comparing a struct.cmp.Transformer
is relaxed and clearly specified.cmpopts.AcyclicTransformer
makes it easier to write a transformer that avoids infinite recursion when the output type contains the input type.cmpopts.IgnoreSliceElements
andcmpopts.IgnoreMapEntries
provide the ability to ignore specific slice elements or map entries.cmp.Reporter
provides users the ability to add custom difference reporters.cmp.PathStep.Values
provide the currentreflect.Value
for thex
andy
arguments at that given path step.Bug fixes:
Reporter changes:
cmp.Diff
output has been completely re-written to provide a unified diff of the two Go objects as a literal in pseudo-Go syntax (example).v0.2.0
Compare Source
Added Features:
Add implicit filter to transformers where a
Transformer
can only apply if that specific transformer does not already exist within the tail of the currentPath
since the last non-transform step. This filter makes it easier to create same-type transformations (e.g.,func(T) T
) without needing to manually add your own filter. (#29)Add
Path.Index
method, which provides an easier way to index aPath
without needing to manually perform bounds checking. (#56)Add
Transform.Option
method, which returns the originalTransformer
option. This enables the creation of non-reentrant transformers. (#59)Add handling for
purego
build tag, which prevents use ofunsafe
, which is necessary to implementAllowUnexported
. However,unsafe
is not available in some build environments such as GopherJS and Google AppEngine Standard. A future release will remove special casing for these two environments. (#68)Reporting changes:
Diff
only batches multiple differences together for slices of primitives. (#45)Diff
prints uses as
prefix to indicate that theString
method was used. (#46)Diff
prints strings using the raw literal syntax when helpful. (#46)Diff
reports the type of a primitive when helpful. (#65)Path.GoString
elides printing type assertions on anonymous types. (#21)Bug fixes:
Configuration
📅 Schedule: At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by WhiteSource Renovate. View repository job log here.