Created
January 4, 2021 21:20
-
-
Save klement97/b177c9315d7b737379f27aedd7fae972 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.mark.django_db | |
def test_order_save(monkeypatch): | |
def mock_post(*args, **kwargs): | |
return None | |
monkeypatch.setattr(requests, 'post', mock_post) | |
order = create_order() | |
assert order.price is not None |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment