Opening-range-breakout engine self-test 2026-10-17T08:21:28.162Z [PASS] ZA: up first candle -> buy at the open of the bar starting 09:35; stop at the range low; target 10 R; filled at the target: 101 99.5 116 target 284.24 [PASS] ZA: down first candle -> sell at 09:35, stopped at the range high; an unchanged first candle -> no trade that day: 2024-03-05 -1 100.5 stop [PASS] the stop and the target touched in the same minute -> the stop; a bar opening below the stop -> filled at its open: 99.5 stop; 98 stop [PASS] no level reached: closed at the close of the bar ending 16:00, or 13:15 on the day after Thanksgiving (early close): 2024-03-05 16:00 102.25; 2024-11-29 13:15 103.1 [PASS] a missing bar inside the opening range -> no trade that day [PASS] BO: a first break up fills one tick above the range high (101.75); stop one tick below the low (99.25); R 2.5; the 10 R target (126.75) not reached, so closed at the session close (116): 101.75 99.25 2.5 116 session close [PASS] BO: a first break down sells one tick below the low and is stopped one tick above the high: 99.25 101.75 stop [PASS] BO: both levels in one minute -> the one nearer the open is entered and the other stops it in the same minute (a full loss): 1 101.75 99.25 stop [PASS] BO: no break before 13:30 -> no trade; a bar opening above the level fills at its open: entry 103 [PASS] long only: the buy trades of the long-and-short rule only [PASS] BO: the target is entry + 10 R = 101.75 + 25 = 126.75, filled at the level; result in dollars after $15.76: 126.75 484.24 [PASS] control: offset 0 reproduces the trades; offset 1 swaps the two days' directions on their own ranges real data: 2373779 minutes to 2026-09-25 17:00 New York; 1735 days with US-session bars, 1733 with the opening range, the 09:35 bar and an exit bar; 58 early closes [PASS] real data: the re-implementation reads the same minutes as the engine's loader (count and every 997th bar): 2373779 vs 2373779 [PASS] the exchange calendar written again gives the same scheduled close as rb_lib.js on every day of 2020 to 2026: 0 differences [PASS] real data: no exit after the scheduled close, and the last bar is the one ending at the scheduled close on at least 98% of the tradable days: 1732 of 1733 exact [PASS] ORB-ZA-LS: engine and independent re-implementation agree trade by trade: 1729 vs 1729 trades, 0 differences [PASS] ORB-ZA-LS: control at offset 0 reproduces the real trades: 1729 of 1729 [PASS] ORB-ZA-L: engine and independent re-implementation agree trade by trade: 877 vs 877 trades, 0 differences [PASS] ORB-ZA-L: control at offset 0 reproduces the real trades: 877 of 877 [PASS] ORB-BO-LS: engine and independent re-implementation agree trade by trade: 1733 vs 1733 trades, 0 differences [PASS] ORB-BO-LS: control at offset 0 reproduces the real trades: 1733 of 1733 [PASS] ORB-BO-L: engine and independent re-implementation agree trade by trade: 866 vs 866 trades, 0 differences [PASS] ORB-BO-L: control at offset 0 reproduces the real trades: 866 of 866 PASSED