test(telegram): guard PTB integration tests with importorskip

CI test slices don't install python-telegram-bot (optional dep), causing
a ModuleNotFoundError on collection. Add pytest.importorskip('telegram')
before the PTB imports.
fix/verification-admin-route-recovery
kshitijk4poor 2026-07-14 17:05:06 +05:30 committed by kshitij
parent c5aaf76468
commit adf62065a7
1 changed files with 2 additions and 0 deletions

View File

@ -3,6 +3,8 @@
import asyncio
import pytest
pytest.importorskip("telegram") # PTB is an optional dependency; skip if absent.
from telegram.error import Conflict, TelegramError
from telegram.request import BaseRequest