GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
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
Shouldn't this be Time.current though, just so we can take Time.zone into account?
I wonder if it matters ...
I went by the existing definition of travel method which uses Time.now.
Would be nice if this also worked with a block, like travel does.
@dhh Added support for block as well.
This is not a deterministic test. This can still pass without the correct implementation, you can get same formatted time 3 times.
Yup, updated the test to be non-deterministic. Please check.
Added time helper method `freeze_time` which is an alias for `travel_…
…to Time.now` (#29681)