Files
wickra/testdata/golden/g_SpreadBollingerBands.csv
T
kingchenc 4f708d410d test: golden-pin the four de-duplicated indicators across all bindings (#305)
* test: golden-pin the four de-duplicated indicators across all C-ABI bindings

Extend gen_golden to emit reference fixtures for AdOscillator (ADOSC),
IntradayIntensity, AwesomeOscillatorHistogram and AverageDrawdown, and replay
them through the Go / C# / Java / R golden harnesses so their corrected
definitions stay bit-identical to the Rust core in every binding. Go suite
verified locally (gcc 13 + cgo): all 9 golden tests pass; C#/Java/R use the
same fixtures and harness pattern (CI-verified). First step of extending the
golden coverage beyond the seven archetype representatives.

* test: golden-pin the scalar-output tranche (308 indicators) against Rust

Extend gen_golden with a generated emit_scalar that writes reference fixtures
for every single-f64-output indicator (scalar / candle / pairwise input) using
valid constructor params, and add a manifest-driven generic Python golden
replay that reconstructs each by its native name and checks it bit-for-bit
against the Rust output. 308 indicators now value-tied to the Rust core in
Python (pytest: 308/308). Takes golden coverage from the 7 archetype
representatives to 308+ of the catalogue.

22 scalar indicators with non-default constructor constraints are skipped by
gen_golden for now (logged), as are non-f64-output ones; multi-output, exotic
inputs and the per-indicator arg arities of the C-ABI/Node replays follow.
Generated + verified locally with the full toolchain.

* test: golden-pin the multi-output tranche (70 indicators) in Python

Add a generated emit_multi to gen_golden (per-indicator Output-field access,
one CSV column per field) and a manifest-driven generic Python replay that
checks every field of each multi-output indicator against the Rust reference.
70 multi-output indicators now value-tied to Rust in Python; combined with the
scalar tranche, 378 indicators are golden-pinned. 8 multi with non-default
param constraints and 5 with non-f64 Output fields (Option/Vec/i64) are
deferred. pytest green.

* test(golden): add 30 constraint-tuned indicators to scalar/multi golden suite

Emit golden fixtures for 22 scalar-output and 8 multi-output indicators
whose constructors need non-default parameters (Alma, Jma, Psar, T3, Mama,
DoubleBollinger, ZigZag, ...). All 408 fixtures replay bit-for-bit through
the Python binding.

* test(golden): cover 36 missed scalar/multi indicators

Add 26 single-output (LinearRegression family, HT cycle, Candle
volatility estimators, DrawdownDuration) and 10 multi-output
(BollingerBands, MACD/MACDEXT/MACDFIX, Camarilla, VWAP bands, ...)
indicators to the golden suite. 444 fixtures replay bit-for-bit
through the Python binding.

* test(golden): cover 50 exotic-input indicators

Add deterministic synthetic feeders for the DerivativesTick (17),
CrossSection (15), Trade (8), TradeQuote (3) and OrderBook (7)
families, derived from the shared OHLCV input series in both
gen_golden and a new Python replay harness (test_golden_exotic).
All 494 fixtures replay bit-for-bit through the Python binding.

* test(golden): complete 514-indicator golden coverage

Add the final tranches: 3 mixed multi-output indicators (Ichimoku,
WilliamsFractals, LeadLagCrossCorrelation), 6 histogram profiles
(time/volume seasonality + TPO/volume price profiles), 10 alt-chart
bar builders and the footprint. Every one of the 514 distinct
indicators now has a Rust-generated g_<Canonical>.csv fixture and a
generic Python replay (scalar/multi/exotic/profile/bars), all passing
bit-for-bit.

* test(golden): add generic Node replay for all 514 indicators

A manifest-driven node:test harness reconstructs every indicator by its
native class, feeds the same synthetic stream derived from the shared
golden input, and checks output bit-for-bit against the Rust reference
fixtures (scalar/multi/exotic/profile/bars). node_manifest.json is
generated from index.d.ts plus the Python-side manifests. 514/514 pass.

* test(golden): add generated Go replay for all 514 indicators

golden_all_test.go (generated by gen_golden_test.py) reconstructs every
Go indicator, feeds the shared synthetic stream and checks output
bit-for-bit against the Rust reference fixtures. A reflection-based
comparator flattens multi-output structs, profiles and bar slices so one
path covers all archetypes. This is the first C-ABI binding verified
across the full catalogue. 514/514 pass.

* test(golden): add generated C# replay for all 514 indicators

GoldenAllTests.g.cs (generated by gen_golden_test.py) reconstructs every
C# indicator, feeds the shared synthetic stream and checks output
bit-for-bit against the Rust reference fixtures via a reflection-based
flatten covering scalar/multi/profile/bar archetypes. 514/514 pass.

Also add the '#nullable enable' directive the compiler requires to the
generated Indicators.g.cs, clearing the four CS8669 warnings on the
nullable double[] profile return types.

* fix(java): marshal C ABI bool params correctly; add 514 golden replay

The Java FFM binding marshalled the cross-section state flags (newHigh,
newLow, aboveMa, onBuySignal) as JAVA_DOUBLE arrays, but the C ABI takes
them as const bool* (one byte each), so the native side read the low byte
of each 8-byte double and saw every flag as false. Add WickraNative.
boolSegment and use it across the 15 cross-section indicators. Also pass
the MacdExt MaType arguments as byte to match the uint8_t downcall
descriptor (was int, throwing WrongMethodTypeException).

Add GoldenAllTest.java (generated by gen_golden_test.py): a reflection
runner replaying all 514 indicators against the Rust reference fixtures.
The bugs above were found by this test; 514/514 now pass.

* fix(r): marshal C ABI bool flags correctly; add 514 golden replay

The R wrapper passed the cross-section state flags as (bool *)REAL(x),
reinterpreting the 8-byte doubles as 1-byte bools so the native side read
every flag as false. Add wk_bool_vec to convert each flag vector into a
real C bool buffer and use it for all 15 cross-section update wrappers.

Add test-golden-all.R + generated golden_specs.R: a reflective runner
replaying all 514 indicators against the Rust reference fixtures. The bug
above was found by this test; verified 514/514 pass locally.

* test(golden): add WASM replay for all 514 indicators

A manifest-driven node:test harness loads the nodejs-target wasm-pack
build, reconstructs every indicator by its JS class, feeds the shared
synthetic stream and checks output bit-for-bit against the Rust
reference fixtures. wasm_manifest.json is generated from the wasm .d.ts
plus the shared manifests; a recursive flattener covers scalar, multi
(Reflect objects), profile and bar shapes. 514/514 pass locally
(wasm-pack build --target nodejs, then node --test).

* test(golden): add C and C++ replay for all 514 indicators

golden_test.c (generated by gen_golden_test.py) drives every indicator
through the C ABI (wickra.h) and checks output bit-for-bit against the
Rust reference fixtures. golden_test.cpp #includes the same source so the
identical runner is compiled and run under both gcc (C) and g++ (C++) via
the CMake targets golden_test / golden_test_cpp — proving the extern "C"
header is consumable from each language. Both 514/514 (verified via ctest).

* test(golden): gofmt the generated Go golden replay

* test(golden): make the Node fixture reader CRLF-safe and pin fixtures to LF
2026-06-15 04:48:51 +02:00

5.3 KiB

1middleupperlowerpercent_b
2nannannannan
3nannannannan
4nannannannan
5nannannannan
6nannannannan
7nannannannan
8nannannannan
9nannannannan
10nannannannan
11nannannannan
12nannannannan
13nannannannan
14nannannannan
150.100680920377098261.5671856354506895-1.3658237946964930.798637534659061
160.08310250997304841.5114705672495936-1.34526554730349670.7348133385344883
170.045177706826237341.414112484869872-1.32375707121739740.6101066376002235
18-0.0038081745792451571.3395940620678024-1.34721041122629260.4472637995664592
19-0.051861682032996521.3251450329727406-1.42886839703873350.30023691436772204
20-0.087217640985677751.3495102317416487-1.52394551371300420.21326768397171267
21-0.101219679603495651.3665518629888116-1.5689912221958030.19479157668825592
22-0.09043961049463841.3530796849804743-1.5339589059697510.24069209849550027
23-0.057516770545009071.327143900592509-1.4421774416825270.3490532134824155
24-0.0105118191984609721.334110830055587-1.3551344684525090.5055545387379881
250.039066792100381271.40156070708023-1.32342712287946740.6630238351043192
260.07908049019104321.4996240453017373-1.3414630649196510.769183393142021
270.099732526254422891.56402100180651-1.36455594929766420.8066560202850594
280.095966561597267381.5516297106607913-1.35969658746625650.7787321436195506
290.068704635710257571.470682827203311-1.33327355578279570.6876691202447431
300.0246214188434379371.375528628150024-1.32628579046314820.5414964842115016
31-0.0254899800582565821.3259676301524586-1.37694759026897180.3781188976104552
32-0.069360542847557021.333720890111726-1.47244197580683990.2539959713687912
33-0.096249225714276221.3600515403737479-1.55254999180230020.19710781672029587
34-0.099572741317040981.364344079859441-1.56348956249352320.20692093751722165
35-0.07851737712463551.340958326604157-1.49799308085342790.28024291689557795
36-0.0382382206228604541.323452191725603-1.39992863297132390.4130033099740635
370.0114029858919571271.3562737839731638-1.33346781218924960.5773445960817635
380.058252343767387671.4439634439615052-1.327458756426730.7172402185391868
390.09083949626704831.5352165961128448-1.35353760357874830.7937894119104404
400.101185971942346761.5688780888981149-1.36650614501342150.802351779365411
410.086758592702015651.522536356146082-1.3490191707420510.746924139363701
420.051089684156529811.427109838196745-1.32493046988368550.629719167487726
430.0029122391144988621.3462378922614895-1.34041341403249170.46930163352429666
44-0.045978223630651121.3238670637034846-1.4158235109647870.31685850174727315
45-0.083611613684410151.3457713837148857-1.51299461108370580.22079557567524843
46-0.100773964651254341.365949127887157-1.56749705718966580.19347081725317605
47-0.093263334456585161.3563830081014534-1.54290967701462380.23095461881396528
48-0.062918587314442221.3297469324678208-1.45558410709670530.33128955720379594
49-0.0171691756352783731.3297931810907817-1.36413153236133830.4833937013400019
500.032783849035334971.3896046638046249-1.3240369657339550.6442324417643185
510.0747102440853911.4871464523940374-1.33772596422325530.7590202819506588
520.098344965772490411.5594227913962826-1.36273285985130180.8055476684514689
530.097901409937895171.5579609159108678-1.36215809603507740.7860889226461063
540.073488174519464361.4837317594413215-1.33675541040239270.7033092559116134
550.0310824709889812661.3865342161004732-1.32436927412251080.5630980224914359
56-0.0189333054786778071.3288367289840555-1.3667033399414110.3986453563036554
57-0.06431354844304391.3305278222388335-1.45915491912492130.26679304399374637
58-0.093947591735136321.3572078532635294-1.5451030367338020.20070116279678463
59-0.100579988033660221.365688027434422-1.56684800350174250.2019421829889777
60-0.082586895411829181.3447588311864465-1.50993262201010480.26688526757173203
61-0.044373650474509771.3236620965062358-1.41240939745525540.3925665644537145
620.0047038116841306991.348203009404551-1.33879538603628960.555656020657547
630.052629616691328961.4306316627864566-1.32537242940379870.7018960570457022
640.08766985601043891.5253379786657377-1.34999826664485980.787643750584985
650.1012454569850741.569077753981039-1.3665868400108910.8049471156903286
660.09003263903100541.532682295927599-1.35261701786558830.757924963943221
670.056776691044087261.4403931798265126-1.32683979773833820.6485076076119257
680.0096198289332524011.3540142695689665-1.3347746117024620.49148442768572037
69-0.039892302803705451.3234187893805462-1.40320339498795720.3345416450754039
70-0.079637407521617421.3419689580261547-1.50124377306938970.22955492958604468
71-0.099884497426550921.364757923158418-1.56452691801151980.193282907351767
72-0.095676378767833071.3593338544322902-1.5506866119679560.22233328402558783
73-0.068043345756384461.3328322950662468-1.46891898657901580.3144947871679775
74-0.0237509286091263271.3266235872621852-1.3741254444804380.46141338577060437
750.0263565442042385771.3783820687835984-1.32566898037512120.6245645359826373
760.070011015779793891.4741960340436686-1.33417400248408070.7476180229530415
770.096524348972918371.553447253643897-1.36039855569806020.8032824485784161
780.099405155133116611.562932715615541-1.3641224053493080.7923308422808695
790.077948112440742941.4963512474827365-1.34045502260125080.717893341516359
800.0374066532874154851.3983075138230079-1.32349420724817680.5842222551693794
81-0.0122932591933115591.3328455391454017-1.3574320575320250.41979501462738084