### Question:
Digest extends AbstractDigest { @Override public DigestAlgorithm getAlgorithm() { return this.algorithm; } Digest(final DigestAlgorithm algorithm, final byte[] digest);  Digest(final byte[] digest); protected  Digest(); @Override DigestAlgorithm getAlgorithm(); @Override byte[] getDigest(); OptionalDigest asOptionalDigest(); static Digest fromString(final String digest); static final Digest SHA1_ZERO; static final Digest SHA1_OF_NO_DATA; }### Answer:
@Test public final void testGetAlgorithm() { final Digest d = new Digest(DigestAlgorithm.SHA1, getTestDigest(20)); Assert.assertEquals(DigestAlgorithm.SHA1, d.getAlgorithm()); }