def test_pre_high_time(self): # method test_pre_high_time checks if the time being # returned from pre_high is not blank stock_symbol = 'aapl' test = after_hours.pre_high(stock_symbol) test = test[2] self.assertNotEqual(test, '', msg='Test pre_high time failed')
def test_pre_high_price(self): # method test_pre_high_price checks if the price being # returned from pre_high is greater than 0 stock_symbol = 'aapl' test = after_hours.pre_high(stock_symbol) test = test[1] self.assertGreater(test, 0, msg='Test pre_high price failed')
def test_pre_high_symbol(self): # method test_pre_high_symbol checks if the symbol being # returned from pre_high is accurate stock_symbol = 'aapl' test = after_hours.pre_high(stock_symbol) test = test[0] self.assertEqual(test, 'aapl', msg='Test pre_high symbol failed')