def test_investpy_technical(): """ This function checks that investpy news retrieval functionality works as expected. """ params = list() for interval in list(investpy.utils.constant.INTERVAL_FILTERS.keys()): params.append({ 'name': 'bbva', 'country': 'spain', 'product_type': 'stock', 'interval': interval }) for param in params: investpy.technical_indicators(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.moving_averages(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.pivot_points(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval'])
def test_investpy_technical(): """ This function checks that investpy news retrieval functionality works as expected. """ params = [ { 'name': 'bbva', 'country': 'spain', 'product_type': 'stock', 'interval': 'weekly', }, { 'name': 'bbva mi inversion rf mixta fi', 'country': 'spain', 'product_type': 'fund', 'interval': 'daily', }, ] for param in params: investpy.technical_indicators(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.moving_averages(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.pivot_points(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval'])
def test_investpy_technical(): """ This function checks that investpy technical retrieval functionality works as expected. """ params = list() for interval in list(investpy.utils.constant.INTERVAL_FILTERS.keys()): params.append({ 'name': 'bbva', 'country': 'spain', 'product_type': 'stock', 'interval': interval }) for param in params: investpy.technical_indicators(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.moving_averages(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) investpy.pivot_points(name=param['name'], country=param['country'], product_type=param['product_type'], interval=param['interval']) issue284 = investpy.technical_indicators(name='bbva', country='spain', product_type='stock', interval='daily') assert len(issue284.columns) == 5 index284 = issue284.index assert len(index284) == 16 assert issue284.columns[0] == 'Name' assert issue284.columns[2] == 'Value' assert issue284.columns[4] == 'Action' assert issue284['Name'][14] == 'Price' assert issue284['Name'][15] == 'DateTimeStamp' assert str(type(issue284['Value'][14])) == "<class 'str'>" assert str(type(issue284['Value'][15])) == "<class 'str'>"