commit:     685c48d1f13accd80509dfa52a62fb93606da62c
Author:     Joe Kappus <joe <AT> wt <DOT> gd>
AuthorDate: Tue Oct 11 18:02:05 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Oct 12 20:44:20 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=685c48d1

net-nntp/sabnzbd: add pytest, fix deps

Merging Kangie's updates to allow for test.

Signed-off-by: Joe Kappus <joe <AT> wt.gd>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-nntp/sabnzbd/sabnzbd-3.6.1.ebuild | 52 +++++++++++++++++++++++++++++------
 1 file changed, 43 insertions(+), 9 deletions(-)

diff --git a/net-nntp/sabnzbd/sabnzbd-3.6.1.ebuild 
b/net-nntp/sabnzbd/sabnzbd-3.6.1.ebuild
index 6f28bd82c53c..22552e21fdd2 100644
--- a/net-nntp/sabnzbd/sabnzbd-3.6.1.ebuild
+++ b/net-nntp/sabnzbd/sabnzbd-3.6.1.ebuild
@@ -39,7 +39,7 @@ DEPEND="
                dev-python/notify2[${PYTHON_USEDEP}]
                dev-python/portend[${PYTHON_USEDEP}]
                dev-python/puremagic[${PYTHON_USEDEP}]
-               >=dev-python/sabyenc-5.4.2[${PYTHON_USEDEP}]
+               <dev-python/sabyenc-6[${PYTHON_USEDEP}]
        ')
 "
 
@@ -53,11 +53,17 @@ BDEPEND="
        test? (
                $(python_gen_cond_dep '
                        dev-python/flaky[${PYTHON_USEDEP}]
+                       >=dev-python/lxml-4.5.0[${PYTHON_USEDEP}]
                        dev-python/pkginfo[${PYTHON_USEDEP}]
                        dev-python/pyfakefs[${PYTHON_USEDEP}]
                        dev-python/pytest-httpbin[${PYTHON_USEDEP}]
                        dev-python/pytest-httpserver[${PYTHON_USEDEP}]
+                       dev-python/pytest[${PYTHON_USEDEP}]
+                       dev-python/requests[${PYTHON_USEDEP}]
                        dev-python/selenium[${PYTHON_USEDEP}]
+                       dev-python/tavalidate[${PYTHON_USEDEP}]
+                       dev-python/tavern[${PYTHON_USEDEP}]
+                       dev-python/werkzeug[${PYTHON_USEDEP}]
                        dev-python/xmltodict[${PYTHON_USEDEP}]
                ')
                www-apps/chromedriver-bin
@@ -72,6 +78,42 @@ pkg_setup() {
        python-single-r1_pkg_setup
 }
 
+src_test() {
+       local EPYTEST_IGNORE=(
+               # network sandbox
+               tests/test_getipaddress.py
+               tests/test_rss.py
+               tests/test_urlgrabber.py
+               tests/test_utils/test_happyeyeballs.py
+               tests/test_utils/test_internetspeed.py
+       )
+       local EPYTEST_DESELECT=(
+               # network sandbox
+               'tests/test_consistency.py::TestWiki'
+               # Just plain fails
+               'tests/test_newsunpack.py::TestPar2Repair::test_basic'
+               # Chromedriver tests don't want to behave in portage
+               
'tests/test_functional_config.py::TestBasicPages::test_base_pages'
+               
'tests/test_functional_config.py::TestBasicPages::test_base_submit_pages'
+               'tests/test_functional_config.py::TestConfigLogin::test_login'
+               
'tests/test_functional_config.py::TestConfigCategories::test_page'
+               
'tests/test_functional_config.py::TestConfigRSS::test_rss_basic_flow'
+               
'tests/test_functional_config.py::TestConfigServers::test_add_and_remove_server'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_basic_rar5'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_zip'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_7zip'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_passworded'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_fully_obfuscated'
+               
'tests/test_functional_downloads.py::TestDownloadFlow::test_download_unicode_rar'
+               'tests/test_functional_misc.py::TestShowLogging::test_showlog'
+               
'tests/test_functional_misc.py::TestQueueRepair::test_queue_repair'
+               
'tests/test_functional_misc.py::TestDaemonizing::test_daemonizing'
+       )
+       epytest -s
+}
+
+
+
 src_install() {
        local d
 
@@ -102,14 +144,6 @@ src_install() {
        systemd_newunit "${FILESDIR}"/sabnzbd_at.service '[email protected]'
 }
 
-src_test() {
-       EPYTEST_IGNORE=(
-               # Requires dev-python/tavern which is not currently packaged 
for Gentoo
-               tests/test_functional_api.py
-       )
-       epytest
-}
-
 pkg_postinst() {
        if [[ -z "${REPLACING_VERSIONS}" ]]; then
                # This is a new installation

Reply via email to