Skip to content

Commit 63057f5

Browse files
Fix Junit 4 assertions in JUnit5 tests
1 parent 37d42bb commit 63057f5

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/test/java/com/amazonaws/encryptionsdk/DecryptRequestTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@
2020
import org.mockito.Mock;
2121
import org.mockito.junit.jupiter.MockitoExtension;
2222

23-
import static org.junit.Assert.assertTrue;
2423
import static org.junit.jupiter.api.Assertions.assertThrows;
24+
import static org.junit.jupiter.api.Assertions.assertTrue;
2525

2626
@ExtendWith(MockitoExtension.class)
2727
class DecryptRequestTest {
2828

2929
@Mock private Keyring keyring;
3030
@Mock private ParsedCiphertext parsedCiphertext;
31-
private static final byte[] CIPHERTEXT = new byte[] {1,2,3};
31+
private static final byte[] CIPHERTEXT = new byte[]{1, 2, 3};
3232

3333
@Test
3434
void testBothCiphertextAndParsedCiphertext() {

src/test/java/com/amazonaws/encryptionsdk/EncryptRequestTest.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,16 @@
1919
import org.mockito.Mock;
2020
import org.mockito.junit.jupiter.MockitoExtension;
2121

22-
import static org.junit.Assert.assertTrue;
2322
import static org.junit.jupiter.api.Assertions.assertEquals;
2423
import static org.junit.jupiter.api.Assertions.assertThrows;
24+
import static org.junit.jupiter.api.Assertions.assertTrue;
2525

2626
@ExtendWith(MockitoExtension.class)
2727
class EncryptRequestTest {
2828

2929
@Mock private Keyring keyring;
3030
@Mock private CryptoMaterialsManager cmm;
31-
private static final byte[] PLAINTEXT = new byte[] {1, 2,3 };
31+
private static final byte[] PLAINTEXT = new byte[]{1, 2, 3};
3232

3333
@Test
3434
void testBothCmmAndKeyring() {
@@ -68,6 +68,6 @@ void testNoEncryptionContext() {
6868
@Test
6969
void testNullPlaintext() {
7070
assertThrows(NullPointerException.class, () -> EncryptRequest.builder()
71-
.keyring(keyring).build());
71+
.keyring(keyring).build());
7272
}
7373
}

0 commit comments

Comments
 (0)