Fix RegressionTests#fromXContent (#46029)

* The `trainingPercent` must be between `1` and `100`, not `0` and `100` which is causing test failures
This commit is contained in:
Armin Braun 2019-08-27 17:23:48 +02:00 committed by Dimitris Athanasiou
parent 4b879848f0
commit fdef293c81
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ public class RegressionTests extends AbstractSerializingTestCase<Regression> {
Integer maximumNumberTrees = randomBoolean() ? null : randomIntBetween(1, 2000);
Double featureBagFraction = randomBoolean() ? null : randomDoubleBetween(0.0, 1.0, false);
String predictionFieldName = randomBoolean() ? null : randomAlphaOfLength(10);
Double trainingPercent = randomBoolean() ? null : randomDoubleBetween(0.0, 100.0, true);
Double trainingPercent = randomBoolean() ? null : randomDoubleBetween(1.0, 100.0, true);
return new Regression(randomAlphaOfLength(10), lambda, gamma, eta, maximumNumberTrees, featureBagFraction,
predictionFieldName, trainingPercent);
}