signalstickers / signalstickers-client

⚙️🐍 A Python client for the Signal stickers API
https://pypi.org/project/signalstickers-client/
GNU Lesser General Public License v3.0
54 stars 9 forks source link

PyPI source does not include test data and mock_httpx.py #22

Open MrRoy opened 10 months ago

MrRoy commented 10 months ago

When downloading the source code from PyPI, the tests folder is missing some files:

$ tar -xvf signalstickers-client-3.3.0.tar.gz 
signalstickers-client-3.3.0/
[...]
signalstickers-client-3.3.0/tests/
signalstickers-client-3.3.0/tests/test_download.py
$

This results in the unit tests failing:

ImportError while importing test module '/var/tmp/portage/portage/dev-python/signalstickers-client-3.3.0-r1/work/signalstickers-client-3.3.0/tests/test_download.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.10/site-packages/_pytest/python.py:617: in _importtestmodule
    mod = import_path(self.path, mode=importmode, root=self.config.rootpath)
/usr/lib/python3.10/site-packages/_pytest/pathlib.py:567: in import_path
    importlib.import_module(module_name)
/usr/lib/python3.10/importlib/__init__.py:126: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
<frozen importlib._bootstrap>:1050: in _gcd_import
    ???
<frozen importlib._bootstrap>:1027: in _find_and_load
    ???
<frozen importlib._bootstrap>:1006: in _find_and_load_unlocked
    ???
<frozen importlib._bootstrap>:688: in _load_unlocked
    ???
/usr/lib/python3.10/site-packages/_pytest/assertion/rewrite.py:186: in exec_module
    exec(co, module.__dict__)
tests/test_download.py:6: in <module>
    from mock_httpx import MockHttpx
E   ModuleNotFoundError: No module named 'mock_httpx'