@Test
public void testDecodeIndexedDynamicArrayValue() {

    DynamicArray<Uint256> array = new DynamicArray<Uint256>(new Uint256(BigInteger.TEN));
    String encoded = TypeEncoder.encodeDynamicArray(array);
    String hash = Hash.sha3(encoded);
    assertThat(FunctionReturnDecoder.decodeIndexedValue(
            hash,
            new TypeReference<DynamicArray>() {}),
            IsEqual.<Type>equalTo(new Bytes32(Numeric.hexStringToByteArray(hash))));
}