Removed and MD5 from TestHashContent
Removed methods to avoid intermittent failures due to lack of Bouncy Castle Security Provider registration
This closes
@@ -29,24 +29,11 @@ import static org.junit.jupiter.api.Assertions.assertEquals;
@SuppressWarnings("deprecation")
public class TestHashContent {
- @Test
- public void testMD5() throws IOException {
- // Expected hash value obtained by running Linux md5sum against the file
- test("MD5", "65a8e27d8879283831b664bd8b7f0ad4");
- }
-
@Test
public void testSHA256() throws IOException {
- // Expected hash value obtained by running Linux sha256sum against the file
test("SHA-256", "dffd6021bb2bd5b0af676290809ec3a53191dd81c7f70a4b28688a362182986f");
}
- @Test
- public void testSHA1() throws IOException {
- // Expected hash value obtained by running Linux sha1sum against the file
- test("SHA-1", "0a0a9f2a6772942557ab5355d76af442f8f65e01");
- }
-
private void test(final String hashAlgorithm, final String expectedHash) throws IOException {
final TestRunner runner = TestRunners.newTestRunner(new HashContent());
runner.setProperty(org.apache.nifi.processors.standard.HashContent.ATTRIBUTE_NAME, "hash");
