removed timeouts from tests, as timeouts were caused by slow JVM stuff like class loading or Cipher.getInstance

This commit is contained in:
Sebastian Stenzel
2015-12-15 21:43:24 +01:00
parent 92e9fc5871
commit 72c0d2cb96
2 changed files with 4 additions and 4 deletions

View File

@@ -29,7 +29,7 @@ public class CryptorImplTest {
};
@Test(timeout = 1000)
@Test
public void testMasterkeyDecryption() throws IOException {
final String testMasterKey = "{\"version\":3,\"scryptSalt\":\"AAAAAAAAAAA=\",\"scryptCostParam\":2,\"scryptBlockSize\":8," //
+ "\"primaryMasterKey\":\"mM+qoQ+o0qvPTiDAZYt+flaC3WbpNAx1sTXaUzxwpy0M9Ctj6Tih/Q==\"," //
@@ -39,7 +39,7 @@ public class CryptorImplTest {
Assert.assertTrue(cryptor.readKeysFromMasterkeyFile(testMasterKey.getBytes(), "asd"));
}
@Test(timeout = 5000)
@Test
public void testMasterkeyEncryption() throws IOException {
final String expectedMasterKey = "{\"version\":3,\"scryptSalt\":\"AAAAAAAAAAA=\",\"scryptCostParam\":16384,\"scryptBlockSize\":8," //
+ "\"primaryMasterKey\":\"BJPIq5pvhN24iDtPJLMFPLaVJWdGog9k4n0P03j4ru+ivbWY9OaRGQ==\"," //

View File

@@ -20,7 +20,7 @@ import org.junit.Test;
public class FilenameCryptorImplTest {
@Test(timeout = 1000)
@Test
public void testDeterministicEncryptionOfFilenames() throws IOException {
final byte[] keyBytes = new byte[32];
final SecretKey encryptionKey = new SecretKeySpec(keyBytes, "AES");
@@ -46,7 +46,7 @@ public class FilenameCryptorImplTest {
Assert.assertEquals(originalPath3, decryptedPath3);
}
@Test(timeout = 1000)
@Test
public void testDeterministicHashingOfDirectoryIds() throws IOException {
final byte[] keyBytes = new byte[32];
final SecretKey encryptionKey = new SecretKeySpec(keyBytes, "AES");