def test_date_type(self): read_price_history(test_log, 5)
def test_no_neg_values(self): max_number = -3 read_price_history(test_log, max_samples=max_number)
def test_date_first(self): after = datetime(2017, 12, 11, 12, 57) max_number = 8 prices = read_price_history(test_log, after, max_number) assert len(prices) == 4
def test_read_max_entries(self): prices = read_price_history(test_log, max_samples=3) assert len(prices) == 3
def test_read_to_date(self): after = datetime(2017, 12, 11, 12, 57) prices = read_price_history(test_log, after) assert len(prices) == 4
def test_read_all_prices(self): prices = read_price_history(test_log) assert len(prices) == 8