You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2020/03/30 21:33:34 UTC

[GitHub] [beam] lukecwik commented on a change in pull request #11096: [BEAM-9399] Change the redirection of System.err to be a custom PrintStream

lukecwik commented on a change in pull request #11096: [BEAM-9399] Change the redirection of System.err to be a custom PrintStream
URL: https://github.com/apache/beam/pull/11096#discussion_r400507824
 
 

 ##########
 File path: runners/google-cloud-dataflow-java/worker/src/test/java/org/apache/beam/runners/dataflow/worker/logging/JulHandlerPrintStreamAdapterFactoryTest.java
 ##########
 @@ -115,6 +116,22 @@ public void testLogOnClose() {
     assertThat(handler.getLogs(), hasLogItem("blah"));
   }
 
+  @Test
+  public void testLogRawBytes() {
+    PrintStream printStream = createPrintStreamAdapter();
+    String msg = "♠ ♡ ♢ ♣ ♤ ♥ ♦ ♧";
+    byte[] bytes = msg.getBytes(UTF_8);
 
 Review comment:
   You have to use the default charset for getBytes since you use the default charset in the CharsetDecoder.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services