public void registerBot(
            String botPath,
            Function<Update, BotApiMethod<?>> updateHandler,
            Runnable setWebhook,
            Runnable deleteWebhook
    ) throws TelegramApiException {
        registerBot(DefaultTelegramWebhookBot
                .builder()
                .botPath(botPath)
                .updateHandler(updateHandler)
                .setWebhook(setWebhook)
                .deleteWebhook(deleteWebhook)
                .build());
    }
@Test
    public void testWhenUpdateIsReceivedOnWebhookUpdateReceivedIsCalledOnCorrectBot() throws TelegramApiException, IOException {
        application.registerBot(telegramWebhookBot);
        TestTelegramWebhookBot telegramWebhookBot2 = new TestTelegramWebhookBot("/test2");
        application.registerBot(telegramWebhookBot2);

        Request request = new Request.Builder()
                .url("http://127.0.0.1:" + webhookOptions.getPort() + "/test")
                .headers(Headers.of(headers))
                .post(RequestBody.create(objectMapper.writeValueAsString(update), MediaType.parse("application/json")))
                .build();

        httpClient.newCall(request).execute();

        assertNotNull(telegramWebhookBot.updateReceived);
        assertEquals(update.getUpdateId(), telegramWebhookBot.updateReceived.getUpdateId());
        assertNull(telegramWebhookBot2.updateReceived);
    }