1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-13 07:34:50 +00:00

Update to 1.3.0

Changes:	https://github.com/sumerc/yappi/blob/master/CHANGELOG
This commit is contained in:
Sunpoet Po-Chuan Hsieh 2020-10-10 17:56:21 +00:00
parent 8941b70106
commit 5ab7b374b9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=551956
4 changed files with 38 additions and 6 deletions

View File

@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= yappi
PORTVERSION= 1.2.5
PORTVERSION= 1.3.0
CATEGORIES= devel python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
@ -13,6 +13,8 @@ COMMENT= Yet Another Python Profiler
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gevent>=20.6.2:devel/py-gevent@${PY_FLAVOR}
USES= python
USE_PYTHON= autoplist concurrent distutils
@ -20,6 +22,6 @@ post-install:
${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/_yappi.so
do-test:
@cd ${WRKSRC} && ${PYTHON_CMD} ${PYDISTUTILS_SETUP} test
cd ${WRKSRC} && ${PYTHON_CMD} ${FILESDIR}/run_tests.py
.include <bsd.port.mk>

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1588092633
SHA256 (yappi-1.2.5.tar.gz) = ad5fa4caf2859e480ffc4ec3e85615a6f7dea852c8f035f2db723f824ed4ba11
SIZE (yappi-1.2.5.tar.gz) = 52806
TIMESTAMP = 1602317879
SHA256 (yappi-1.3.0.tar.gz) = a443240f4a776fa1be04430bf423dbf09615c05eba34f4a2a6af344a7ce8ff61
SIZE (yappi-1.3.0.tar.gz) = 58200

View File

@ -0,0 +1,31 @@
import unittest
import sys
def _testsuite_from_tests(tests):
suite = unittest.TestSuite()
loader = unittest.defaultTestLoader
for t in tests:
test = loader.loadTestsFromName('tests.%s' % (t))
suite.addTest(test)
return suite
if __name__ == '__main__':
sys.path.append('tests/')
test_loader = unittest.defaultTestLoader
test_runner = unittest.TextTestRunner(verbosity=2)
tests = ['test_functionality', 'test_hooks', 'test_tags', 'test_gevent']
if sys.version_info >= (3, 4):
tests += ['test_asyncio']
if sys.version_info >= (3, 7):
tests += ['test_asyncio_context_vars']
test_suite = test_loader.loadTestsFromNames(tests)
if len(sys.argv) > 1:
test_suite = _testsuite_from_tests(sys.argv[1:])
#tests = ['test_functionality.BasicUsage.test_run_as_script']
result = test_runner.run(test_suite)
sys.exit(not result.wasSuccessful())

View File

@ -3,5 +3,4 @@ Yappi is designed to work on long-running multi-threaded applications.
It is possible to profile an application, retrieve statistics, then stop and
start later on the fly without affecting the profiled application.
WWW: https://pypi.org/project/yappi/
WWW: https://github.com/sumerc/yappi