-
-
Save jasongorman/ad01d4bdc6ab2e4208050f1f31715921 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
def test_sales_sent_to_charts(self): | |
song = 'How Do You Sleep: Sam Smith' | |
all_sales = [ | |
Sale(song) | |
] | |
charts_mock = Charts() | |
from unittest.mock import MagicMock | |
charts_mock.send = MagicMock() | |
daily_sales = DailySongSales(all_sales, charts_mock) | |
daily_sales.sales_of(song) | |
charts_mock.send.assert_called_with(song, 1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment