File tree Expand file tree Collapse file tree
src/test/java/org/apache/commons/codec/digest Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -279,7 +279,7 @@ void testTreeIdBuilderAddFileInputStream() throws Exception {
279279 @ Test
280280 void testTreeIdBuilderInvalidPathSegments () {
281281 final MessageDigest md = DigestUtils .getSha1Digest ();
282- final byte [] data = new byte [ 0 ] ;
282+ final byte [] data = {} ;
283283 // Sole path component
284284 assertThrows (IllegalArgumentException .class ,
285285 () -> GitIdentifiers .treeIdBuilder (md ).addFile (GitIdentifiers .FileMode .REGULAR , ".." , data ));
@@ -308,7 +308,7 @@ void testTreeIdBuilderNestedFileEquivalentToDirectoryAndFile() throws Exception
308308
309309 @ ParameterizedTest
310310 @ ValueSource (strings = {"" , "." })
311- void testTreeIdBuilderNoopPathSegments (String segment ) throws Exception {
311+ void testTreeIdBuilderNoopPathSegments (final String segment ) throws Exception {
312312 final MessageDigest md = DigestUtils .getSha1Digest ();
313313 final byte [] content = "hello\n " .getBytes (StandardCharsets .UTF_8 );
314314
You can’t perform that action at this time.
0 commit comments