[CodeFactor] Apply fixes to commit f7dcc20

This commit is contained in:
codefactor-io
2026-09-21 09:51:53 +00:00
parent dfc2951383
commit 009a26b6c5
+8 -8
View File
@@ -72,7 +72,7 @@ public class EeoTests
for (int i = 0; i < 500; i++)
{
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 0.1));
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 0.1)));
}
Assert.True(indicator.IsHot);
@@ -98,7 +98,7 @@ public class EeoTests
// Warm up past the threshold first
for (int i = 0; i < 65; i++)
{
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 0.5), isNew: true);
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 0.5)), isNew: true);
}
TValue r1 = indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(80), 120.0), isNew: true);
@@ -193,7 +193,7 @@ public class EeoTests
for (int i = 0; i < 200; i++)
{
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 0.1));
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 0.1)));
if (indicator.IsHot && hotAt < 0)
{
hotAt = i;
@@ -213,7 +213,7 @@ public class EeoTests
for (int i = 0; i < 70; i++)
{
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 0.1));
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 0.1)));
}
TValue nanResult = indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(70), double.NaN));
@@ -228,7 +228,7 @@ public class EeoTests
for (int i = 0; i < 70; i++)
{
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 0.1));
indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 0.1)));
}
TValue infResult = indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(70), double.PositiveInfinity));
@@ -244,7 +244,7 @@ public class EeoTests
for (int i = 0; i < 100; i++)
{
source[i] = 100.0 + i * 0.5;
source[i] = 100.0 + (i * 0.5);
}
source[50] = double.NaN;
@@ -337,7 +337,7 @@ public class EeoTests
for (int i = 0; i < size; i++)
{
source[i] = 100.0 + i * 0.1;
source[i] = 100.0 + (i * 0.1);
}
Eeo.Batch(source, output, 20);
@@ -432,7 +432,7 @@ public class EeoTests
for (int i = 0; i < 100; i++)
{
TValue r = indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + i * 2.0));
TValue r = indicator.Update(new TValue(DateTime.UtcNow.AddSeconds(i), 100.0 + (i * 2.0)));
lastResult = r.Value;
}