Tests for hmac