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

Add cop for time in expect #127

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

RitamBanerjee
Copy link
Contributor

What did we change?

We don't want people asserting on a call to Time

Why are we doing this?

This leads to flaky time bomb tests

How was it tested?

  • Specs
  • Locally

@RitamBanerjee RitamBanerjee requested review from a team as code owners December 18, 2023 22:35
@RitamBanerjee RitamBanerjee requested review from maudineormsby and jbeard6 and removed request for a team December 18, 2023 22:35
Copy link
Contributor

@jmpage jmpage left a comment

Choose a reason for hiding this comment

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

Mind updating the CHANGELOG and version.rb as well as the README to note the existence of this cop?

@maudineormsby
Copy link

Very nice!

Copy link

@jaeger401 jaeger401 left a comment

Choose a reason for hiding this comment

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

LGTM. In ez-rails, we've traditionally encouraged the use of :freeze_time to mitigate this, but it makes sense to add safety to our other code bases which may not have a spec helper like that. (And this should help limit flakiness in ez-rails too.)

I concur with Jen -- could you please update CHANGELOG.md, version.rb, and the README? Happy to approve once those are updated!

Copy link

@jbeard6 jbeard6 left a comment

Choose a reason for hiding this comment

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

I concur with Jen -- could you please update CHANGELOG.md, version.rb, and the README? Happy to approve once those are updated!

Ditto.

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.

5 participants