----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/54542/#review158603 -----------------------------------------------------------
geode-core/src/test/java/org/apache/geode/internal/InternalDataSerializerRandomizedJUnitTest.java (line 102) <https://reviews.apache.org/r/54542/#comment229379> Since you named the variable codepoint maybe something like this would be more appropriate: int codepoint = ...; char character = (new Character(codepoint)).charValue(); stringBuilder.append(character); If you want to keep the code you have you need to change the "if" statement to (stringBuilder.length() + numdigits(codepoint) < strlen) because StringBuilder.append(int) is going to convert the int to a String, like "12345" and append it. - Bruce Schuchardt On Dec. 8, 2016, 10:10 p.m., Galen O'Sullivan wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/54542/ > ----------------------------------------------------------- > > (Updated Dec. 8, 2016, 10:10 p.m.) > > > Review request for geode, Bruce Schuchardt, Hitesh Khamesra, and Udo > Kohlmeyer. > > > Bugs: GEODE-2191 > https://issues.apache.org/jira/browse/GEODE-2191 > > > Repository: geode > > > Description > ------- > > * Added a new test that generates random strings, and attempts to serialize > and deserialize them looking for differences or errors. > > > Diffs > ----- > > > geode-core/src/test/java/org/apache/geode/internal/InternalDataSerializerRandomizedJUnitTest.java > PRE-CREATION > > Diff: https://reviews.apache.org/r/54542/diff/ > > > Testing > ------- > > This is a new test; I've run it both from IntelliJ and as a part of the test > suite. I filed GEODE-2191 for this; I'm not sure if a new JIRA is strictly > necessary for any new changes but it does seem to be encouraged. > > I don't know of any random string generator that is already available in the > codebase; had there been one I would have used it rather than rolling my own. > We could eventually use something like > [junit-quickcheck](https://github.com/pholser/junit-quickcheck) for these > types of tests. > > > Thanks, > > Galen O'Sullivan > >