DIST pyshark-0.3.7.2.tar.gz 27232 BLAKE2B b93ee24fb29990b0ab455935e773e4844c26761c2515d1254c8e72d24d70be95aa17a590cc1f5b39bb5f76db624fb7c40d06e64731948ee75a5b8e2008830968 SHA512 dbd97665fae7d3067582bf7616e025b0c5e5fa14cacdaca59c89b4e70feb3017f2d8c7d899a70c0c8707589e4735b9283914bb6ccbf432e9072c64d7e957bc15
+DIST pyshark-0.4.2.3.tar.gz 29363 BLAKE2B 91463f725eb893c3c7f7442eec5e0a8304bb8f2ecbd0ea80582c49bfd8538a5fcdb1d5d1ab2373f8e67684c78c8852af697dadf8ff041d42f8ff18a8954a6248 SHA512 bbef857dad5e5141e0ec7c04dba9faca81b17d67a7151959e9935577428cd1415e173e9c7ededff46f8621bcbbdfbe7a96ca5cfd65d7143fb6f235c0167964b6
dev-python/lxml[${PYTHON_USEDEP}]
dev-python/trollius[${PYTHON_USEDEP}]
virtual/python-futures[${PYTHON_USEDEP}]
- net-analyzer/wireshark"
+ net-analyzer/wireshark[tshark]"
DEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
test? (
--- /dev/null
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+PYTHON_COMPAT=( python3_{5,6} )
+
+inherit distutils-r1 eutils
+
+DESCRIPTION="A Python wrapper for tshark output parsing"
+HOMEPAGE="https://pypi.org/project/pyshark/ https://github.com/KimiNewt/pyshark"
+# pypi tarball is missing tests
+#SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+SRC_URI="https://github.com/KimiNewt/pyshark/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="test"
+
+# See pyshark.egg-info/requires.txt
+RDEPEND="
+ dev-python/py[${PYTHON_USEDEP}]
+ dev-python/logbook[${PYTHON_USEDEP}]
+ dev-python/lxml[${PYTHON_USEDEP}]
+ dev-python/trollius[${PYTHON_USEDEP}]
+ virtual/python-futures[${PYTHON_USEDEP}]
+ net-analyzer/wireshark[tshark]"
+DEPEND="
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ test? (
+ ${RDEPEND}
+ dev-python/pytest[${PYTHON_USEDEP}]
+ )
+"
+
+S="${WORKDIR}/${P}/src"
+
+python_prepare_all() {
+ # Test fails unless portage can execute /usr/bin/dumpcap
+ # https://github.com/KimiNewt/pyshark/issues/197
+ rm "${WORKDIR}/${P}/tests/capture/test_inmem_capture.py" || die
+ distutils-r1_python_prepare_all
+}
+
+python_test() {
+ cd "${WORKDIR}/${P}/tests" || die
+ py.test -v || die
+}