Browse Source

Fix test error

I made a mistake in a randomized test in #70653. It didn't trigger on my
PRs but the intake caught it. I just misplaced a decimal place.
Nik Everett 4 years ago
parent
commit
2633b92bb3

+ 1 - 1
x-pack/plugin/sql/qa/server/src/main/java/org/elasticsearch/xpack/sql/qa/FieldExtractorTestCase.java

@@ -230,7 +230,7 @@ public abstract class FieldExtractorTestCase extends BaseRestSqlTestCase {
         // because "coerce" is true, a "123.456" floating point number STRING should be converted to 123.456 as number
         // and converted to 123.5 for "scaled_float" type
         // and 123.4375 for "half_float" because that is all it stores.
-        double expectedNumber = isScaledFloat ? 123.5 : fieldType.equals("half_float") ? 123.4375 : 1234.56;
+        double expectedNumber = isScaledFloat ? 123.5 : fieldType.equals("half_float") ? 123.4375 : 123.456;
         expected.put("rows", singletonList(singletonList(expectedNumber)));
         assertResponse(expected, runSql("SELECT " + fieldType + "_field FROM test"));
     }