django-step-by-step
django-step-by-step copied to clipboard
Poetry - Separate test dependencies from dev dependencies
2 Parts to this issue:
Part 1
It seems the latest idiomatic way to define dependencies is:
[tool.poetry.group.dev.dependencies]
instead of:
[tool.poetry.dev-dependencies]
See: "A note about defining a dev dependencies group" here
Part 2
To separate dev
and test
dependencies—after the above change is made—we would simply need to move some items in the pyproject.toml into a new [tool.poetry.group.test.dependencies]
group. I have found it helpful to separate out the test
dependencies for github actions / CI purposes.