Skip to content
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

Make sure time.Time comparison produces a helpful diff. closes #989 #1072

Merged
merged 1 commit into from
Apr 27, 2021

Conversation

HaraldNordgren
Copy link
Contributor

@HaraldNordgren HaraldNordgren commented Apr 24, 2021

Make sure time.Time comparison produces a helpful diff. closes #989

Summary

Make sure time.Time comparison produces a helpful diff
again. This partially reverses the changes in #895 for
time.Time and allows it to be easily expanded for more
types in the future if needed.

Changes

Analyzes the type when diffing, and uses a different
Spew config for time.Time

Introduce a test for diffing time.Time

Motivation

See bug #989

Related issues

Closes #989

@HaraldNordgren
Copy link
Contributor Author

Ping @AlekSi @Jozmen @boyan-soubachov

@HaraldNordgren
Copy link
Contributor Author

This fixes the issue introduced for time.Time in #895 :)

Ping @luan @glesica

@HaraldNordgren
Copy link
Contributor Author

Hi, could we please get some attention on this one? :)

Copy link
Collaborator

@boyan-soubachov boyan-soubachov left a comment

Choose a reason for hiding this comment

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

Thank you for fixing this :)

@boyan-soubachov boyan-soubachov merged commit dc5c261 into stretchr:master Apr 27, 2021
@HaraldNordgren
Copy link
Contributor Author

HaraldNordgren commented Apr 27, 2021

@boyan-soubachov Thanks for approving :))

@HaraldNordgren
Copy link
Contributor Author

@boyan-soubachov Can we please get a v1.7.1 release as well? :)

@boyan-soubachov
Copy link
Collaborator

@boyan-soubachov Can we please get a v1.7.1 release as well? :)

I will keep this in master for now in order to get feedback and find out if there are any issues. You can just use testify@master in your go.mod to use the latest master of testify (or if you want to pin to a commit digest, that should work too if I remember correctly)

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.

time.Time comparison produces non-helpful diff
3 participants