Installation¶
Quick start¶
Install everything:
This includes all plugins and their optional dependencies (httpx, requests, aiohttp, websockets, websocket-client, redis, psycopg2, asyncpg, dirty-equals).
Selective installation¶
For a more compact installation, pick only the extras you need:
pip install bigfoot # Core plugins (no extra deps)
pip install bigfoot[http] # + HttpPlugin (httpx, requests, urllib)
pip install bigfoot[aiohttp] # + aiohttp support for HttpPlugin
pip install bigfoot[psycopg2] # + Psycopg2Plugin (PostgreSQL)
pip install bigfoot[asyncpg] # + AsyncpgPlugin (async PostgreSQL)
pip install bigfoot[websockets] # + AsyncWebSocketPlugin
pip install bigfoot[websocket-client] # + SyncWebSocketPlugin
pip install bigfoot[redis] # + RedisPlugin
pip install bigfoot[matchers] # + dirty-equals matchers
Core plugins (no extra dependencies)¶
These plugins are always available with a bare pip install bigfoot:
MockPlugin-- general-purpose mock objectsSubprocessPlugin--subprocess.runandshutil.whichPopenPlugin--subprocess.PopenAsyncSubprocessPlugin--asyncio.create_subprocess_exec/shellDatabasePlugin--sqlite3.connectSmtpPlugin--smtplib.SMTPSocketPlugin--socket.socketLoggingPlugin--logging.Logger
Matcher support¶
dirty-equals matchers can be used as expected field values in assertions:
pytest fixture¶
The bigfoot_verifier pytest fixture is registered automatically via the pytest11 entry point. No conftest.py changes are needed:
def test_example(bigfoot_verifier):
# bigfoot_verifier is a StrictVerifier with automatic verify_all() at teardown
...
Or use the context manager directly: