question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Tests failing for master branch

See original GitHub issue

Have attached the complete output but typically getting errors similar to

import file mismatch: imported module 'data.clientmodule_test' has this __file__ attribute: /home/tariquesani/Projects/lektor/venv/lib/python2.7/site-packages/astroid/tests/testdata/python2/data/clientmodule_test.py which is not the same as the test file we want to collect: /home/tariquesani/Projects/lektor/venv/lib/python2.7/site-packages/astroid/tests/testdata/python3/data/clientmodule_test.py HINT: remove __pycache__ / .pyc files and/or use a unique basename for your test file modules ERROR collecting venv/lib/python2.7/site-packages/astroid/tests/testdata/python3/data/suppliermodule_test.py

testreport.txt

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
singingwolfboycommented, Feb 13, 2017

Ah, I see the problem. The README says to create the virtualenv inside of the lektor directory, but if you do that, then pytest will pick up all the files inside the virtualenv and try to test them as well. If you create the virtualenv outside of the lektor directory, then most of the tests pass – except for two, which seem to be failing on Ubuntu locally. I’m not sure what’s going on with those tests, but I’ll look into it in the next few days.

Could someone else please verify that removing the venv directory and using a different virtualenv outside of the lektor directory works correctly? If so, I would love a pull request updating the install documentation.

0reactions
tariquesanicommented, Feb 13, 2017

Moving venv outside indeed did the trick. Infact all 164 tests passed for me!

Bah! I should have figured that one out myself - the error messages indicates that. Hmmm… hindsight is always 20/20

Read more comments on GitHub >

github_iconTop Results From Across the Web

Failing on the master branch instead of failing on...
If you had failing test, created a branch, fixed it locally on a branch, pushed to repository and Bamboo states it's failing a...
Read more >
Unit tests are failing on master branch · Issue #1826 - GitHub
Some of the unit tests are failing on master branch. This is causing the azure builds to fail for all the open pull...
Read more >
How to avoid pushing to master branch if cypress test fails on ...
So everytime I push changes to development branch, github runs the cypress tests and notifies if it passed or failed in github Actions....
Read more >
Post-commit tests policies - Apache Beam
Jenkins executes post-commit tests against the HEAD of the master branch. If post-commit tests fail, there is a problem with the HEAD build....
Read more >
If two individual branches pass unit tests, once they're merged ...
If you test the merged combined code, then the test failure can be caused by either an issue on the source branch (feature)...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found