fixed test cases

This commit is contained in:
2021-02-22 15:54:38 -05:00
parent 5c0054861f
commit 196295f8ed
5 changed files with 15 additions and 7 deletions

View File

@@ -38,6 +38,14 @@
</dependency>
</dependencies>
<reporting>
<plugins>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
</plugin>
</plugins>
</reporting>
<distributionManagement>
<repository>
<id>inteligr8-releases</id>

View File

@@ -52,7 +52,7 @@ public abstract class AbstractHashingByteChannelUnitTest {
@Test
public void javaDigestBuffer() throws Exception {
this.test("sha-256", new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "0cdd4be589eada9c9ff37160ed46b4951361dab6b7eb0bfc1234436e37b6edc7");
this.test("sha-256", new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "c82a52583fc3319b117c6bee33781ef6cafb5058e77236271dbb636ba08ee3f1");
}
public void test(String algorithm, String text, String hex) throws Exception {

View File

@@ -23,7 +23,7 @@ public class Md5DigestUnitTest extends AbstractDigestUnitTest {
@Test
public void fileText() throws Exception {
this.validateFile(new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "606b3a677a91eddfe8b5ddd493f7be8f");
this.validateFile(new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "8dac62e518f9e0eb7decfbd890461275");
}
}

View File

@@ -23,7 +23,7 @@ public class Sha256DigestUnitTest extends AbstractDigestUnitTest {
@Test
public void fileText() throws Exception {
this.validateFile(new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "0cdd4be589eada9c9ff37160ed46b4951361dab6b7eb0bfc1234436e37b6edc7");
this.validateFile(new File("src/main/java/com/inteligr8/nio/DigestBuffer.java"), "c82a52583fc3319b117c6bee33781ef6cafb5058e77236271dbb636ba08ee3f1");
}
}

View File

@@ -39,8 +39,8 @@ public class StreamingCryptoByteChannelUnitTest {
}
@Test
public void streamNioCryptoJar100() throws IOException, InterruptedException, TimeoutException, ExecutionException {
File jar = new File(m2dir, "repository/com/inteligr8/nio-crypto/1.0-SNAPSHOT/nio-crypto-1.0-SNAPSHOT.jar");
public void streamSmallJar() throws IOException, InterruptedException, TimeoutException, ExecutionException {
File jar = new File(m2dir, "repository/org/slf4j/slf4j-api/1.7.30/slf4j-api-1.7.30.jar");
this.stream(jar, 16384);
this.stream(jar, 1024);
this.stream(jar, 32);
@@ -49,8 +49,8 @@ public class StreamingCryptoByteChannelUnitTest {
}
@Test
public void streamAlfrescoPdfRenderer11() throws IOException, InterruptedException, TimeoutException, ExecutionException {
File war = new File(m2dir, "repository/org/alfresco/alfresco-pdf-renderer/1.1/alfresco-pdf-renderer-1.1-win64.tgz");
public void streamBigJar() throws IOException, InterruptedException, TimeoutException, ExecutionException {
File war = new File(m2dir, "repository/junit/junit/4.12/junit-4.12.jar");
this.stream(war, 16384);
}