You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
because I'm calling build with --no-isolation I'm using during all processes only locally installed modules
install .whl file in </install/prefix>
run pytest with PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>
I'm usimg pkgconfig 1.9.3.
Here is pytest output:
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-pkgconfig-1.5.5-5.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-pkgconfig-1.5.5-5.fc35.x86_64/usr/lib/python3.8/site-packages+ /usr/bin/pytest -ra=========================================================================== test session starts ============================================================================platform linux -- Python 3.8.13, pytest-7.1.2, pluggy-1.0.0rootdir: /home/tkloczko/rpmbuild/BUILD/pkgconfig-1.5.5collected 35 itemstest_pkgconfig.py F.......FF.F.F.F.F.F......F........ [100%]================================================================================= FAILURES =================================================================================_______________________________________________________________________________ test_exists ________________________________________________________________________________ def test_exists(): assert pkgconfig.exists(PACKAGE_NAME)
> assert pkgconfig.exists('fake-openssl')E AssertionError: assert FalseE + where False = <function exists at 0x7fc8cbfb0280>('fake-openssl')E + where <function exists at 0x7fc8cbfb0280> = pkgconfig.existstest_pkgconfig.py:12: AssertionError________________________________________________________________________ test_openssl[1.1.0j-True] _________________________________________________________________________version = '1.1.0j', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '1.1.0j')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError_______________________________________________________________________ test_openssl[==1.1.0j-True] ________________________________________________________________________version = '==1.1.0j', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '==1.1.0j')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError_______________________________________________________________________ test_openssl[>= 1.1.0-True] ________________________________________________________________________version = '>= 1.1.0', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '>= 1.1.0')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError________________________________________________________________________ test_openssl[< 1.2.0-True] ________________________________________________________________________version = '< 1.2.0', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '< 1.2.0')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError________________________________________________________________________ test_openssl[>= 1.1-True] _________________________________________________________________________version = '>= 1.1', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '>= 1.1')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError_________________________________________________________________________ test_openssl[< 1.2-True] _________________________________________________________________________version = '< 1.2', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '< 1.2')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError_______________________________________________________________________ test_openssl[>= 1.1.0c-True] _______________________________________________________________________version = '>= 1.1.0c', expected = True @pytest.mark.parametrize("version,expected", [ ('1.1.0j', True), ('==1.1.0j', True), ('==1.1.0k', False), ('>= 1.1.0', True), ('> 1.2.0', False), ('< 1.2.0', True), ('< 1.1.0', False), ('>= 1.1', True), ('> 1.2', False), ('< 1.2', True), ('< 1.1', False), ('>= 1.1.0c', True), ('>= 1.1.0k', False), # PLEASE NOTE: # the letters have no semantics, except string ordering, see also the # comment in the test below. # comparing release with beta, like "1.2.3" > "1.2.3b" does not work. ]) def test_openssl(version, expected):
> assert pkgconfig.installed('fake-openssl', version) == expectedE AssertionError: assert False == TrueE + where False = <function installed at 0x7fc8cbfb0670>('fake-openssl', '>= 1.1.0c')E + where <function installed at 0x7fc8cbfb0670> = pkgconfig.installedtest_pkgconfig.py:48: AssertionError_____________________________________________________________________________ test_modversion ______________________________________________________________________________ def test_modversion(): assert pkgconfig.modversion(PACKAGE_NAME) == '3.2.1'
> assert pkgconfig.modversion('fake-openssl') == '1.1.0j'test_pkgconfig.py:79:_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _pkgconfig/pkgconfig.py:154: in modversion _raise_if_not_exists(package)_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _package = 'fake-openssl' def _raise_if_not_exists(package): if not exists(package):
> raise PackageNotFoundError(package)E pkgconfig.pkgconfig.PackageNotFoundError: fake-openssl not foundpkgconfig/pkgconfig.py:103: PackageNotFoundError========================================================================= short test summary info ==========================================================================FAILED test_pkgconfig.py::test_exists - AssertionError: assert FalseFAILED test_pkgconfig.py::test_openssl[1.1.0j-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[==1.1.0j-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[>= 1.1.0-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[< 1.2.0-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[>= 1.1-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[< 1.2-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_openssl[>= 1.1.0c-True] - AssertionError: assert False == TrueFAILED test_pkgconfig.py::test_modversion - pkgconfig.pkgconfig.PackageNotFoundError: fake-openssl not found======================================================================= 9 failed, 26 passed in 0.98s =======================================================================
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesI'm usimg pkgconfig 1.9.3.
Here is pytest output:
Here is list of installed modules in build env
The text was updated successfully, but these errors were encountered: