fix: OKX options buy/close orders with tick alignment and reduceOnly
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -5,6 +5,13 @@ from lib.options.options_pricing_lib import (
|
||||
sheets_from_eth_amount,
|
||||
total_premium,
|
||||
)
|
||||
from lib.exchange.okx_options_lib import format_option_px, round_option_px
|
||||
|
||||
|
||||
def test_round_option_px():
|
||||
assert round_option_px(14.9184, "0.2", "sell") == 14.8
|
||||
assert round_option_px(14.81, "0.2", "buy") == 15.0
|
||||
assert format_option_px(14.8, "0.2") == "14.8"
|
||||
|
||||
|
||||
def test_premium_per_sheet():
|
||||
|
||||
Reference in New Issue
Block a user