You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by or...@apache.org on 2022/12/07 11:41:20 UTC
[camel] branch main updated: (chores) camel-hdfs: use standard charsets on tests
This is an automated email from the ASF dual-hosted git repository.
orpiske 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 bb2ffa78847 (chores) camel-hdfs: use standard charsets on tests
bb2ffa78847 is described below
commit bb2ffa78847dcf12bc519cdda67e1169516c99d7
Author: Otavio Rodolfo Piske <an...@gmail.com>
AuthorDate: Wed Dec 7 11:36:38 2022 +0100
(chores) camel-hdfs: use standard charsets on tests
---
.../org/apache/camel/component/hdfs/integration/HdfsAppendIT.java | 4 +++-
.../camel/component/hdfs/integration/HdfsConsumerIntegrationIT.java | 3 ++-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsAppendIT.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsAppendIT.java
index 2dd1d80da69..c75b7a3f916 100644
--- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsAppendIT.java
+++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsAppendIT.java
@@ -16,6 +16,8 @@
*/
package org.apache.camel.component.hdfs.integration;
+import java.nio.charset.StandardCharsets;
+
import org.apache.camel.Exchange;
import org.apache.camel.builder.RouteBuilder;
import org.apache.camel.test.infra.hdfs.v2.services.HDFSService;
@@ -70,7 +72,7 @@ public class HdfsAppendIT extends CamelTestSupport {
}
try (FSDataOutputStream out = fs.create(file)) {
for (int i = 0; i < 10; ++i) {
- out.write("PIPPO".getBytes("UTF-8"));
+ out.write("PIPPO".getBytes(StandardCharsets.UTF_8));
}
}
}
diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsConsumerIntegrationIT.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsConsumerIntegrationIT.java
index fbb2103b1d8..5c59db63075 100644
--- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsConsumerIntegrationIT.java
+++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/integration/HdfsConsumerIntegrationIT.java
@@ -18,6 +18,7 @@ package org.apache.camel.component.hdfs.integration;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
+import java.nio.charset.StandardCharsets;
import java.util.HashSet;
import java.util.Set;
import java.util.concurrent.CountDownLatch;
@@ -75,7 +76,7 @@ public class HdfsConsumerIntegrationIT extends CamelTestSupport {
FileSystem fs = FileSystem.get(file.toUri(), conf);
try (FSDataOutputStream out = fs.create(file)) {
for (int i = 0; i < 1024; ++i) {
- out.write(("PIPPO" + i).getBytes("UTF-8"));
+ out.write(("PIPPO" + i).getBytes(StandardCharsets.UTF_8));
out.flush();
}
}