On Thu, 9 Dec 2021 18:14:39 GMT, Lance Andersen <lan...@openjdk.org> wrote:
>> Andrew Leonard has updated the pull request incrementally with one >> additional commit since the last revision: >> >> 8276766: Enable jar and jmod to produce deterministic timestamped content >> >> Signed-off-by: Andrew Leonard <anleo...@redhat.com> > > test/jdk/tools/jar/ReproducibleJar.java line 95: > >> 93: "2006-04-06T12:38:00", >> 94: "2012-08-24T16"}; >> 95: > > Another good use of a DataProvider done > test/jdk/tools/jar/ReproducibleJar.java line 193: > >> 191: >> 192: // Check jars are identical >> 193: checkSameContent(jarFileSourceDate1, jarFileSourceDate2); > > You could if you choose use: > > Assert.assertEquals(Files.readAllBytes(jarFileSourceDate1.toPath(), > Files.readAllBytes(jarFileSourceDate2.toPath())); done > test/jdk/tools/jar/ReproducibleJar.java line 219: > >> 217: } >> 218: >> 219: static void checkFileTime(long now, long original) throws Throwable >> { > > Please add a basic comment of the intent of the method done > test/jdk/tools/jar/ReproducibleJar.java line 241: > >> 239: } >> 240: >> 241: static void checkSameContent(File f1, File f2) throws Throwable { > > See comment above for consideration regarding the use of Assert.assertEquals done ------------- PR: https://git.openjdk.java.net/jdk/pull/6481