async def METHOD_NAME(device_code: AuthCodeQuery, interceptor: RequestInterceptor, google: SimulatedGoogle, server) -> None:
    await device_code.requestCredentials(google._custom_drive_client_id, google._custom_drive_client_secret)
    match = interceptor.setError(URL_MATCH_TOKEN)
    match.addResponse(json_response(data={}, status=403))
    google._device_code_accepted = False
    with pytest.raises(GoogleCredGenerateError) as error:
        await device_code.waitForPermission()
    assert error.value.message() == "Google refused the request to connect your account, either because you rejected it or they were set up incorrectly."