Development
Setting up for Development
To set up a development environment, clone the repository and install the development dependencies:
git clone https://github.com/simple-salesforce/simple-salesforce.git
cd simple-salesforce
pip install -e .[dev]
This will install the package in editable mode along with all development dependencies including tox, pytest, pylint, mypy, and other testing/linting tools.
Running Tests
The project uses tox for testing across multiple Python versions. To run all tests:
tox
To run tests for a specific Python version:
tox -e py312-unit # Run unit tests with Python 3.12
To run static analysis (linting and type checking):
tox -e static
To run tests directly with pytest (after installing dev dependencies):
pytest
Available tox environments:
py{39,310,311,312,313}-unit- Run unit tests with different Python versionsstatic- Run pylint and mypy for code quality checksdocs- Build documentationclean- Clean up coverage files
Contributing
Pull requests are welcome! Please make sure to:
Run tests with
toxto ensure compatibility across Python versionsFollow the existing code style (enforced by the static analysis tools)
Add tests for any new functionality