Skip to content
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

1.6.1: pytest cannot find test units and setuptools test fails #163

Open
kloczek opened this issue Dec 22, 2021 · 2 comments
Open

1.6.1: pytest cannot find test units and setuptools test fails #163

kloczek opened this issue Dec 22, 2021 · 2 comments

Comments

@kloczek
Copy link

kloczek commented Dec 22, 2021

  • Support request or Bug

I cannot find any testing methodology details so ..
pytest cannot find any units:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-strictyaml-1.6.1-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-strictyaml-1.6.1-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.12, pytest-6.2.5, py-1.11.0, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/strictyaml-1.6.1
plugins: datadir-1.3.1, regressions-2.2.0, forked-1.4.0, cov-3.0.0, xdist-2.5.0
collected 0 items

========================================================================== no tests ran in 0.12s ===========================================================================

and setuptools test fails:

+ /usr/bin/python3 setup.py test
running test
WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox.
running egg_info
no previously-included directories found matching 'hitch/__pycache__'
no previously-included directories found matching 'hitch/gen'
writing manifest file 'strictyaml.egg-info/SOURCES.txt'
running build_ext
cyaml (unittest.loader._FailedTest) ... ERROR

======================================================================
ERROR: cyaml (unittest.loader._FailedTest)
----------------------------------------------------------------------
ImportError: Failed to import test module: cyaml
Traceback (most recent call last):
  File "/usr/lib64/python3.8/unittest/loader.py", line 154, in loadTestsFromName
    module = __import__(module_name)
  File "/home/tkloczko/rpmbuild/BUILD/strictyaml-1.6.1/strictyaml/ruamel/cyaml.py", line 5, in <module>
    from _ruamel_yaml import CParser, CEmitter  # type: ignore
ModuleNotFoundError: No module named '_ruamel_yaml'


----------------------------------------------------------------------
Ran 1 test in 0.000s

Something is missing in my build env?

@crdoconnor
Copy link
Owner

crdoconnor commented Dec 24, 2021 via email

@kloczek
Copy link
Author

kloczek commented Dec 24, 2021

Need to check what exactly it is that hitchkey however one of the most populat methods or frameworks of testing python code is pytest so this is why I've been trying to use it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants