Create a Telegram Bot for OpenAI API which storing chat history in the PostgreSQL. Give the user option to retrieve the past conversations and select one to continue or resume the conversation. Please implement the application using the following python packages:
- python-telegram-bot
- SQLAlchemy
- asyncpg
- pytest
- pytest-asyncio
- aiosqlite
Please make sure all codes written with comprehensive test coverage.