fedora-python / pyp2rpm

Tool to convert a package from PyPI to RPM SPECFILE or to generate SRPM.
MIT License
125 stars 39 forks source link

testing: disable network #57

Closed glensc closed 8 years ago

glensc commented 8 years ago

please allow running tests that do not require network

so i could enable basic testing in distro build environment where network access is not permitted

hroncok commented 8 years ago

I see that in Fedora, this is done in not very clean way:

http://pkgs.fedoraproject.org/cgit/rpms/pyp2rpm.git/tree/rm_url_test.patch

I suggest we use a marker, like @pytest.mark.webtest

hroncok commented 8 years ago

@glensc Do you happen to have list of tests that fail with no network?

glensc commented 8 years ago

NjUN.txt

but it's mixed with other errors not just network errors

mcyprian commented 8 years ago

The only test that doesn't work for me without network connection is test_get_url, I added @pytest.mark.webtest to it in 3fc59dabcc3671.