These could be properties.
This commit is contained in:
@@ -259,7 +259,7 @@ def test_dca_buying(default_conf_usdt, ticker_usdt, fee, mocker) -> None:
|
||||
|
||||
assert trade.amount == trade.orders[0].amount + trade.orders[1].amount
|
||||
|
||||
assert trade.nr_of_successful_buys() == 2
|
||||
assert trade.nr_of_successful_buys == 2
|
||||
|
||||
# Sell
|
||||
patch_get_signal(freqtrade, value=(False, True, None, None))
|
||||
@@ -273,4 +273,4 @@ def test_dca_buying(default_conf_usdt, ticker_usdt, fee, mocker) -> None:
|
||||
assert trade.orders[-1].side == 'sell'
|
||||
assert trade.orders[2].amount == trade.amount
|
||||
|
||||
assert trade.nr_of_successful_buys() == 2
|
||||
assert trade.nr_of_successful_buys == 2
|
||||
|
@@ -1553,7 +1553,7 @@ def test_recalc_trade_from_orders_ignores_bad_orders(fee):
|
||||
assert trade.open_rate == o1_rate
|
||||
assert trade.fee_open_cost == o1_fee_cost
|
||||
assert trade.open_trade_value == o1_trade_val
|
||||
assert trade.nr_of_successful_buys() == 1
|
||||
assert trade.nr_of_successful_buys == 1
|
||||
|
||||
order2 = Order(
|
||||
ft_order_side='buy',
|
||||
@@ -1580,7 +1580,7 @@ def test_recalc_trade_from_orders_ignores_bad_orders(fee):
|
||||
assert trade.open_rate == o1_rate
|
||||
assert trade.fee_open_cost == o1_fee_cost
|
||||
assert trade.open_trade_value == o1_trade_val
|
||||
assert trade.nr_of_successful_buys() == 1
|
||||
assert trade.nr_of_successful_buys == 1
|
||||
|
||||
# Let's try with some other orders
|
||||
order3 = Order(
|
||||
@@ -1608,7 +1608,7 @@ def test_recalc_trade_from_orders_ignores_bad_orders(fee):
|
||||
assert trade.open_rate == o1_rate
|
||||
assert trade.fee_open_cost == o1_fee_cost
|
||||
assert trade.open_trade_value == o1_trade_val
|
||||
assert trade.nr_of_successful_buys() == 1
|
||||
assert trade.nr_of_successful_buys == 1
|
||||
|
||||
order4 = Order(
|
||||
ft_order_side='buy',
|
||||
@@ -1635,7 +1635,7 @@ def test_recalc_trade_from_orders_ignores_bad_orders(fee):
|
||||
assert trade.open_rate == o1_rate
|
||||
assert trade.fee_open_cost == 2 * o1_fee_cost
|
||||
assert trade.open_trade_value == 2 * o1_trade_val
|
||||
assert trade.nr_of_successful_buys() == 2
|
||||
assert trade.nr_of_successful_buys == 2
|
||||
|
||||
# Just to make sure sell orders are ignored, let's calculate one more time.
|
||||
sell1 = Order(
|
||||
@@ -1662,4 +1662,4 @@ def test_recalc_trade_from_orders_ignores_bad_orders(fee):
|
||||
assert trade.open_rate == o1_rate
|
||||
assert trade.fee_open_cost == 2 * o1_fee_cost
|
||||
assert trade.open_trade_value == 2 * o1_trade_val
|
||||
assert trade.nr_of_successful_buys() == 2
|
||||
assert trade.nr_of_successful_buys == 2
|
||||
|
Reference in New Issue
Block a user