Skip to content

Commit b19a9b3

Browse files
committed
Change stop losses and take profits name
1 parent ff89e46 commit b19a9b3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

tests/scenarios/test_strategy_with_stop_losses_take_profits.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,15 @@ class FixedStopLossTakeProfitStrategy(TradingStrategy):
3232
percentage_of_portfolio=20.0
3333
),
3434
]
35-
take_profit_rules = [
35+
take_profits = [
3636
TakeProfitRule(
3737
symbol="BTC",
3838
percentage_threshold=10.0,
3939
trailing=False,
4040
sell_percentage=100
4141
),
4242
]
43-
stop_loss_rules = [
43+
stop_losses = [
4444
StopLossRule(
4545
symbol="BTC",
4646
percentage_threshold=10.0,
@@ -269,15 +269,15 @@ def test_trailing_stop_loss_take_profit_rule_triggers(self):
269269
start_date = datetime(2020, 12, 29, tzinfo=timezone.utc)
270270
end_date = datetime(2021, 1, 31, 22, 0, 0, tzinfo=timezone.utc)
271271
strategy = FixedStopLossTakeProfitStrategy()
272-
strategy.take_profit_rules = [
272+
strategy.take_profits = [
273273
TakeProfitRule(
274274
symbol="BTC",
275275
percentage_threshold=10.0,
276276
trailing=True,
277277
sell_percentage=100
278278
),
279279
]
280-
strategy.stop_loss_rules = [
280+
strategy.stop_losses = [
281281
StopLossRule(
282282
symbol="BTC",
283283
percentage_threshold=10.0,

0 commit comments

Comments
 (0)