amor71 / LiuAlgoTrader

Framework for algorithmic trading
MIT License
785 stars 130 forks source link

Rename this here and in `test_alpaca_concurrency_ranges_min` #390

Closed github-actions[bot] closed 1 year ago

github-actions[bot] commented 1 year ago

Rename this here and in test_alpaca_concurrency_ranges_min

https://github.com/amor71/LiuAlgoTrader/blob/68941bc93fc23564f0101cfee7944ba2620e92f3/tests/test_data_date_ranges.py#L84


    ):
        raise AssertionError("expected 0")

def test_alpaca_concurrency_ranges_min():
    print("test_alpaca_concurrency_ranges_min")
    alpaca_dl = data_loader_factory(DataConnectorType.alpaca)

    t = _extracted_from_test_alpaca_concurrency_ranges_min_5(
        alpaca_dl, "2021-11-10", 5, "expected 5"
    )
    t = _extracted_from_test_alpaca_concurrency_ranges_min_5(
        alpaca_dl, "2022-01-01", 2, "expected 2"
    )

# TODO Rename this here and in `test_alpaca_concurrency_ranges_min`
def _extracted_from_test_alpaca_concurrency_ranges_min_5(
    alpaca_dl, start, arg2, arg3
):
    result = time.time()
    if (
        len(
            alpaca_dl.data_concurrency_ranges(
                symbol="AAPL",
                start=start,
                end="2022-01-07",
                scale=TimeScale.minute,
            )
        )
        != arg2
    ):
        raise AssertionError(arg3)
    print(time.time() - result)

    return result

@settings(deadline=None, max_examples=100)

455ef3faee455212596303b27366bb4cb8b1d7a8

github-actions[bot] commented 1 year ago

Stale issue message