Files
spark/testing/manual/spreader_misc/simple_sanity.txt
T

19 lines
1.1 KiB
Plaintext

This test makes sure the basic spreader functionality works for 2 legged synthetic spreads with one quoting leg
0. Follow the instructions from docs/spreader_common_setup_1.txt
1. Enter a synthetic buy order of 1 lot at -0.30. Verify that a quoting order of 18.60 shows up in the second leg.
Cancel the synthetic order and the quoting order should be cancelled too.
2. Enter a synthetic buy order of 1 lot at -0.30, again. Now drag the the synthetic order down the ladder (ie lower bid prices) to a few random prices of your choice. Verify that the quoter leg price is adjusted accordingly and is correct.
(If you have followed the instructions in common_setup_1.txt: Leg_1 will buy at 18.300 , and leg_2 will be your quoting leg)
spread_price == price_mult_1 * leg_1 + price_mult_2 * leg_2
leg_2 == price_mult_1 * leg_1 - spread_price / -1.0 * price_mult_2
3. Now cross the synthetic order by dragging it all the way to -0.20 (there should be a 1 lot at that price).
Verify that the synthetic order gets filled at -0.20, the quoter order at 18.50, and the hedger order at 18.30.