### Question:
SecretEncoder { @Nonnull public Single<byte[]> decodeSecret(@Nonnull final BigInteger encodedSecret) { checkNotNull(encodedSecret, "\'encodedSecret\' must not be null."); return Single.fromCallable(() -> { final byte[] secretWithLeading1 = encodedSecret.toByteArray(); final byte[] secretWithoutLeading1 = new byte[secretWithLeading1.length - 1]; System.arraycopy(secretWithLeading1, 1, secretWithoutLeading1, 0, secretWithoutLeading1.length); return secretWithoutLeading1; }); }  @Nonnull Single<BigInteger> encodeSecret(@Nonnull final byte[] secret); @Nonnull Single<byte[]> decodeSecret(@Nonnull final BigInteger encodedSecret);  }### Answer:
@Test(expected = IllegalArgumentException.class) public void testDecodeSecret_nullEncodedSecret() { secretEncoder.decodeSecret(null); }