Created
June 19, 2019 19:57
-
-
Save briggleman/bdbf7bad04d4529878eabc06d00d82c7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@pytest.fixture(autouse=True) | |
def today(): | |
return datetime(2018, 4, 17, 22, 42, 41, 717625) | |
@pytest.fixture(autouse=True) | |
def miso(today): | |
# patches the datetime function in helpers.response | |
# to use this patch call miso.isoformat() in the response to render the same time | |
with mock.patch("sea.helpers.response.converters.datetime") as mocked: | |
mocked.isoformat.return_value = datetime.isoformat(today) | |
yield mocked |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment