This is an automated email from the ASF dual-hosted git repository.

klease pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 3932e7df740 Fix locale issue in float formatting
3932e7df740 is described below

commit 3932e7df740bfa54546da173cfb50692417706d5
Author: klease <kle...@cegetel.net>
AuthorDate: Thu May 5 17:18:03 2022 +0200

    Fix locale issue in float formatting
---
 .../test/java/org/apache/camel/jsonpath/JsonPathCustomMapperTest.java  | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git 
a/components/camel-jsonpath/src/test/java/org/apache/camel/jsonpath/JsonPathCustomMapperTest.java
 
b/components/camel-jsonpath/src/test/java/org/apache/camel/jsonpath/JsonPathCustomMapperTest.java
index 1b462dd36db..6518c05bde5 100644
--- 
a/components/camel-jsonpath/src/test/java/org/apache/camel/jsonpath/JsonPathCustomMapperTest.java
+++ 
b/components/camel-jsonpath/src/test/java/org/apache/camel/jsonpath/JsonPathCustomMapperTest.java
@@ -18,6 +18,7 @@ package org.apache.camel.jsonpath;
 
 import java.io.File;
 import java.io.IOException;
+import java.util.Locale;
 
 import com.fasterxml.jackson.core.JsonGenerator;
 import com.fasterxml.jackson.databind.JsonSerializer;
@@ -39,7 +40,7 @@ public class JsonPathCustomMapperTest extends 
CamelTestSupport {
 
         @Override
         public void serialize(Double value, JsonGenerator gen, 
SerializerProvider serializers) throws IOException {
-            gen.writeRawValue(String.format("%.6f", value));
+            gen.writeRawValue(String.format(Locale.US, "%.6f", value));
         }
     }
 

Reply via email to