dweiss commented on code in PR #14518:
URL: https://github.com/apache/lucene/pull/14518#discussion_r2054478021
##########
lucene/core/src/test/org/apache/lucene/util/TestArrayUtil.java:
##########
@@ -113,16 +119,11 @@ public void testParseInt() throws Exception {
parseInt("0.34");
});
- int test = parseInt("1");
- assertTrue(test + " does not equal: " + 1, test == 1);
- test = parseInt("-10000");
- assertTrue(test + " does not equal: " + -10000, test == -10000);
- test = parseInt("1923");
- assertTrue(test + " does not equal: " + 1923, test == 1923);
- test = parseInt("-1");
- assertTrue(test + " does not equal: " + -1, test == -1);
- test = ArrayUtil.parseInt("foo 1923 bar".toCharArray(), 4, 4);
- assertTrue(test + " does not equal: " + 1923, test == 1923);
+ assertThat(parseInt("1"), equalTo(1));
+ assertThat(parseInt("-10000"), equalTo(-10000));
+ assertThat(parseInt("1923"), equalTo(1923));
+ assertThat(parseInt("-1"), equalTo(-1));
+ assertThat(ArrayUtil.parseInt("foo 1923 bar".toCharArray(), 4, 4),
equalTo(1923));
Review Comment:
Sure, true, if you're using it the first time perhaps. :)
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]