@@ -80,7 +80,7 @@ def __init__(self, name, period):
8080
8181 protected override IndicatorBase < IBaseData > CreateIndicator ( )
8282 {
83- return new PythonIndicator ( CreatePythonIndicator ( ) ) ;
83+ return new PythonIndicator ( CreatePythonIndicator ( ) , false ) ;
8484 }
8585
8686 protected override string TestFileName => "spy_with_indicators.txt" ;
@@ -135,13 +135,13 @@ protected override void RunTestIndicator(IndicatorBase<IBaseData> indicator)
135135 }
136136
137137 protected override Action < IndicatorBase < IBaseData > , double > Assertion => ( indicator , expected ) =>
138- Assert . AreEqual ( expected , ( double ) indicator . Current . Value , 1e-2 ) ;
138+ Assert . AreEqual ( expected , ( double ) indicator . Current . Value , 1e-2 ) ;
139139
140140 [ Test ]
141141 public void SmaComputesCorrectly ( )
142142 {
143143 var sma = new SimpleMovingAverage ( 4 ) ;
144- var data = new [ ] { 1m , 10m , 100m , 1000m , 10000m , 1234m , 56789m } ;
144+ var data = new [ ] { 1m , 10m , 100m , 1000m , 10000m , 1234m , 56789m } ;
145145
146146 var seen = new List < decimal > ( ) ;
147147 for ( int i = 0 ; i < data . Length ; i ++ )
@@ -327,9 +327,9 @@ public void AllPythonRegisterIndicatorBadCases(string consolidatorName, bool nee
327327 Consolidator = Consolidator . Invoke ( ) ;
328328 }
329329
330- #pragma warning disable CS0618
330+ #pragma warning disable CS0618
331331 var exception = Assert . Throws < ArgumentException > ( ( ) => algorithm . RegisterIndicator ( spy , PyIndicator , Consolidator ) ) ;
332- #pragma warning restore CS0618
332+ #pragma warning restore CS0618
333333 Assert . That ( exception . Message , Is . EqualTo ( expectedMessage ) ) ;
334334 }
335335 }
@@ -362,7 +362,7 @@ def Update(self, input):
362362 ) ;
363363 var pythonIndicator = module . GetAttr ( "CustomSimpleMovingAverage" )
364364 . Invoke ( "custom" . ToPython ( ) , 14 . ToPython ( ) ) ;
365- var SMAWithWarmUpPeriod = new PythonIndicator ( pythonIndicator ) ;
365+ var SMAWithWarmUpPeriod = new PythonIndicator ( pythonIndicator , false ) ;
366366 var reference = new DateTime ( 2000 , 1 , 1 , 0 , 0 , 0 ) ;
367367 var period = ( ( IIndicatorWarmUpPeriodProvider ) SMAWithWarmUpPeriod ) . WarmUpPeriod ;
368368
@@ -404,7 +404,7 @@ def Update(self, input):
404404 ) ;
405405 var pythonIndicator = module . GetAttr ( "CustomSimpleMovingAverage" )
406406 . Invoke ( "custom" . ToPython ( ) , 14 . ToPython ( ) ) ;
407- var indicator = new PythonIndicator ( pythonIndicator ) ;
407+ var indicator = new PythonIndicator ( pythonIndicator , false ) ;
408408
409409 Assert . AreEqual ( 0 , indicator . WarmUpPeriod ) ;
410410 }
@@ -421,7 +421,7 @@ public void PythonIndicatorDoesntRequireWrappingToWork()
421421 using ( Py . GIL ( ) )
422422 {
423423 using dynamic customSma = CreatePythonIndicator ( period ) ;
424- var wrapper = new PythonIndicator ( customSma ) ;
424+ var wrapper = new PythonIndicator ( customSma , false ) ;
425425
426426 for ( int i = 0 ; i < data . Length ; i ++ )
427427 {
@@ -486,7 +486,7 @@ public void PythonIndicatorExtensionInRegressionAlgorithm()
486486 {
487487 var parameter = new RegressionTests . AlgorithmStatisticsTestParameters (
488488 "CustomIndicatorWithExtensionAlgorithm" ,
489- new ( ) ,
489+ new ( ) ,
490490 Language . Python ,
491491 AlgorithmStatus . Completed ) ;
492492
0 commit comments