public static byte[] generateTransactionHash(
            RawTransaction rawTransaction, Credentials credentials) {
        byte[] signedMessage = TransactionEncoder.signMessage(rawTransaction, credentials);
        return Hash.sha3(signedMessage);
    }
@Test
    public void testGenerateTransactionHash() {
        assertEquals(
                generateTransactionHashHexEncoded(
                        TransactionEncoderTest.createContractTransaction(), SampleKeys.CREDENTIALS),
                ("0xc3a0f520404c8cd0cb1c98be6b8e17ee32bf134ac1697d078e90422525c2d902"));
    }