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