Testing Pdm Datareader With Pytest

Write and run pytest tests for the pdm-datareader library, focused on mocking the parts that cannot run in CI — pyodbc/SQLAlchemy engines and connections, Azure AD access tokens (msal-bearer), and query() execution. Covers module-global state resets, engine-cache assertions, and token-leak safety checks. Use when adding tests for tools.py, mocking database or auth, or fixing failing/ flaky tests.

equinor e317ad5 5.2 KB Updated

File contents

equinor/pdm-datareader/tree/main/.github/skills/python/testing-patterns commit e317ad5054

Frequently asked questions

npx skillmds@latest add equinor/testing-pdm-datareader-with-pytest