async def METHOD_NAME() -> None:
    """Test the function for checking JWT validity."""
    TEST_KEY = "this is a test key to test having a key"
    valid_token = jwt.encode(
        payload={"exp": datetime.now() + timedelta(days=100), "aud": "fake_audience"},
        key=TEST_KEY,
        algorithm="HS512",
    )
    assert jwt_is_valid(TEST_KEY, valid_token, "fake_audience")
    # Wrong audience
    assert not jwt_is_valid(TEST_KEY, valid_token, "different_audience")
    # Wrong key
    assert not jwt_is_valid(TEST_KEY + "more text", valid_token, "fake_audience")
    # Create an expired key
    invalid_token = jwt.encode(
        payload={"exp": datetime.now() - timedelta(days=100), "aud": "fake_audience"},
        key=TEST_KEY,
        algorithm="HS512",
    )
    assert not jwt_is_valid(TEST_KEY, invalid_token, "fake_audience")