Comments (5)
Thank you for reporting! I am experiencing similar issues, resulting in all the tests to be collected to run, I am now removing the --collect-only to check if that is the cause of that issue.
from pytest-testmon.
Hi @adam-mrozik, I'm trying to reproduce your problem. I have three files with three test in each file. Running
pytest --collect--only --testmon
for the first time lists all tests (3 modules / 3 function tests each). Running
pytest --testmon
as next step will execute all 9 tests with no problem.
Does your workflow differ?
Thanks in advance for any updates.
from pytest-testmon.
Hmm, lately I have actually been noticing, that I have similar issue to @emavgl . I am still trying to debug if there isn't some internal workflow issue on my side.
My workflow currently consists of generating testmon file on CI after each run, and after merge replacing master
testmon file.
This, however breaks in two cases:
- When someone reverts/merges without CICD completing (then I am having an out-of-date testmon file)
- When PR is merged if it is out of date with master.
I am looking if any of these do break the testmon behaviour. Right now though I am experiencing a lot of random things, some of them like @emavgl reported. Will let you now when I am able to reproduce, cause I am aware my report is semi-useful right now
root@c74a0f828c43:/app/accounts# pytest tests --testmon
=========================================================================================================== test session starts ===========================================================================================================
platform linux -- Python 3.8.16, pytest-7.2.0, pluggy-1.0.0
testmon: changed files: 0, skipping collection of 101 files, environment: default
rootdir: /app/accounts
plugins: forked-1.4.0, hypothesis-6.46.7, testmon-1.4.2, flaky-3.7.0, cov-3.0.0, timeout-2.1.0, case-1.5.3 xdist-2.5.0
collected 415 items / 193 deselected / 222 selected
One thing that is weird for me is testmon recognizing there are 0 changes, but still decides to run some tests. Do you know what might be the reason?
from pytest-testmon.
Unfortunately I have also hard time to reproduce the issue, since I have experienced this on a big project. If can help I add some details:
-
have integrated testmon in Github Actions. I save the testmon database using Github action cache.
-
I run it in conjunction with xdist plugin with
python -m pytest -n 4 tests/integration --dist loadfile --testmon
- my pytests have fixtures and conftest files
I was running testmon with collect only with the purpose of listing the pytest tests to be executed
python -m pytest tests/integration --testmon-nocollect --collect-only -q
I am still not exactly sure that collect only is the issue. I have recently removed it and I will keep monitoring it in the next days. So far I did two runs with no problems.
from pytest-testmon.
There has been quite a lot of changes recently in testmon and no news regarding this. Please reach out in case you have problems with testmon with a new ticket.
from pytest-testmon.
Related Issues (20)
- Collection seems to be skipped after a run HOT 9
- testmon doesn't track sources in venv directory HOT 4
- testmon does not respect test order HOT 2
- Ability to run testmon on an installed package HOT 4
- No source package upload to pypi HOT 4
- fails when git is not present HOT 2
- Missing git version tags🤔 HOT 2
- Changes > 1.4.5 made testmon more sensitive to differently packaged environments? HOT 13
- Have a command line that outputs all the tests which reach a certain line in the code HOT 1
- Change to Importlib introduces AttributeError for {d.name} if d.name does not exist. HOT 2
- Temporary files not being cleared inside a container HOT 6
- testmon.org appears to be down HOT 4
- testmon does not work with --branch based coverage HOT 4
- Change to less restrictive license HOT 8
- Seeking examples of pytest-testmon in GitHub Actions HOT 4
- Allow using --testmon-noselect and --testmon-nocollect simultaneously HOT 3
- Mark test as 'run-always'
- Support pytest 8.0
- Support detecting changes in symlinked files HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pytest-testmon.