validation and profiles

This commit is contained in:
Miha Kralj
2026-02-26 22:02:52 -08:00
parent 9ab37c1200
commit 8a1ba95173
317 changed files with 18704 additions and 622 deletions
@@ -1,3 +1,5 @@
using OoplesFinance.StockIndicators;
using OoplesFinance.StockIndicators.Models;
using Skender.Stock.Indicators;
using Xunit.Abstractions;
@@ -88,4 +90,19 @@ public sealed class BbbValidationTests : IDisposable
_output.WriteLine("BBB validated successfully against Skender PercentB.");
}
[Fact]
public void Bbb_MatchesOoples_Structural()
{
// CalculateBollingerBandsPercentB — structural test
var ooplesData = _testData.SkenderQuotes
.Select(q => new TickerData { Date = q.Date, Open = (double)q.Open, High = (double)q.High, Low = (double)q.Low, Close = (double)q.Close, Volume = (double)q.Volume })
.ToList();
var result = new StockData(ooplesData).CalculateBollingerBandsPercentB();
var values = result.CustomValuesList;
int finiteCount = values.Count(v => double.IsFinite(v));
Assert.True(finiteCount > 100, $"Expected >100 finite Ooples BBB values, got {finiteCount}");
}
}