pytest-capsqlalchemy
Pytest plugin to allow capturing SQLAlchemy queries.
- Github repository: https://github.com/softwareone-platform/pytest-capsqlalchemy/
- Documentation https://softwareone-platform.github.io/pytest-capsqlalchemy/
Getting Started
1. Clone the repository
First, clone the repository from GitHub:
git clone https://github.com/softwareone-platform/pytest-capsqlalchemy
2. Set Up Your Development Environment
Then, install the environment and the pre-commit hooks with
make install
This will also generate your uv.lock file
3. Run the pre-commit hooks
Initially, the CI/CD pipeline might be failing due to formatting issues. To resolve those run:
uv run pre-commit run -a
4. Run the tests
The tests require a Postgres database to be running. If you prefer to use a local database you need to edit the .env file with
the connection options for it. Alternatively, you can use the provided docker-compose.yaml to run it within docker -- all you
need to do is run:
docker compose up test_postgres -d
And after that to run the tests:
make test
5. Commit the changes
Lastly, commit the changes made by the two steps above to your repository.
git add .
git commit -m 'Fix formatting issues'
git push origin main
You are now ready to start development on your project! The CI/CD pipeline will be triggered when you open a pull request, merge to main, or when you create a new release.
To finalize the set-up for publishing to PyPI, see here. For activating the automatic documentation with MkDocs, see here.
Metadata
Release files for pytest-capsqlalchemy 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pytest_capsqlalchemy-0.2.1.tar.gz | 85.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pytest_capsqlalchemy-0.2.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 98.4 kB
Release files / pytest_capsqlalchemy-0.2.1.tar.gz
| Download URL | pytest_capsqlalchemy-0.2.1.tar.gz |
|---|---|
| Size | 85.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
77a1876c5a46fe9806731a684db6a51184a7cbe567805a3859d91fc4e3c541cb
|
|
BLAKE2b-256 checksum How to use checksums |
3537e0c7a80fb5b79e33c9a5b7e89bc59a9d0e33017e2d83062d8137971ad01a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 19, 2025.
Transparency logRelease files / pytest_capsqlalchemy-0.2.1-py3-none-any.whl
| Download URL | pytest_capsqlalchemy-0.2.1-py3-none-any.whl |
|---|---|
| Size | 12.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8b5a26e5a32de2d52b35dc55bf9a2277613bf3c440256df4cb7bbdb8a3dc79a3
|
|
BLAKE2b-256 checksum How to use checksums |
361a0172de0ecfac30ccb4cbc47adc64c24f6e560c4ca04f325a5af1135f309f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 19, 2025.
Transparency log