-
-
Notifications
You must be signed in to change notification settings - Fork 10
run bobtemplates.plone subtemplate generated tests #318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
davisagli
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you try adjusting the testpaths in pyproject.toml? What was the error when you ran all the tests together?
|
This is the error when running pytests with both folders as parameters: And this is the output if I run it directly only with the tests folder inside the package: If I adjust the testpath in This is how the [tool.pytest.ini_options]
-testpaths = ["tests"]
+testpaths = ["tests", "src/collective/collectivecocotero/tests/"] |
In plone/bobtemplates.plone#599 I have reworked the tests that bobtemplates.plone subtemplate creates changing the layer names to mimic the ones that cookieplone creates.
Doing that, we can run those tests with pytest, but to do so we need to call pytest passing the
testsfolder as a parameter.I have tried calling pytest with both folders as parameters, but tests fail, if I run in separate statements they run correctly.
This is a first step of the process, a second step would be to generate those tests directly in pytest-style instead of unitest, and move them to the root
testsfolder.