@Test
public void testGenerateNonce() {

    // As this is a "unique" identifier, we call the function twice to
    // ensure it doesn't return the same value
    byte[] nonce1 = Utils.generateNonce();
    byte[] nonce2 = Utils.generateNonce();
    Assert.assertNotNull(nonce1);
    Assert.assertNotNull(nonce2);
    Assert.assertNotEquals("generateNonce returned a duplicate nonce!", nonce1, nonce2);
}