From owner-svn-ports-head@FreeBSD.ORG Sun Feb 16 07:01:04 2014 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9C1D15E6; Sun, 16 Feb 2014 07:01:04 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 84AA514A5; Sun, 16 Feb 2014 07:01:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s1G714Ve067809; Sun, 16 Feb 2014 07:01:04 GMT (envelope-from koobs@svn.freebsd.org) Received: (from koobs@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s1G713nP067804; Sun, 16 Feb 2014 07:01:03 GMT (envelope-from koobs@svn.freebsd.org) Message-Id: <201402160701.s1G713nP067804@svn.freebsd.org> From: Kubilay Kocak Date: Sun, 16 Feb 2014 07:01:03 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r344501 - in head/www/py-grequests: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 16 Feb 2014 07:01:04 -0000 Author: koobs Date: Sun Feb 16 07:01:03 2014 New Revision: 344501 URL: http://svnweb.freebsd.org/changeset/ports/344501 QAT: https://qat.redports.org/buildarchive/r344501/ Log: www/py-grequests: Modernise and fix tests - Enable STAGE support - Enable AUTOPLIST support, delete pkg-plist - RUN_DEPENDS: Use requests 2.x - Deprecate easy_install target - Update LICENSE (BSD2CLAUSE) - Add TEST_DEPENDS - Make tests work using standard setup.py test command [1] - Backport commit for tests using requests hook **kwargs [2] [1] https://github.com/kennethreitz/grequests/pull/47 [2] https://github.com/kennethreitz/grequests/commit/f50782ad63607b85e5e009f4a0a4ce0a8a6aef0d Added: head/www/py-grequests/files/patch-tests__test_grequests.py (contents, props changed) Deleted: head/www/py-grequests/pkg-plist Modified: head/www/py-grequests/Makefile head/www/py-grequests/files/patch-setup.py Modified: head/www/py-grequests/Makefile ============================================================================== --- head/www/py-grequests/Makefile Sun Feb 16 06:06:48 2014 (r344500) +++ head/www/py-grequests/Makefile Sun Feb 16 07:01:03 2014 (r344501) @@ -3,17 +3,19 @@ PORTNAME= grequests PORTVERSION= 0.2.0 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= www python PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} MAINTAINER= koobs@FreeBSD.org COMMENT= Requests with Gevent to make asyncronous HTTP requests -LICENSE= BSD +LICENSE= BSD2CLAUSE RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}gevent>0:${PORTSDIR}/devel/py-gevent \ - ${PYTHON_PKGNAMEPREFIX}requests1>=1.0.0:${PORTSDIR}/www/py-requests1 + ${PYTHON_PKGNAMEPREFIX}requests>=1.0.0:${PORTSDIR}/www/py-requests +TEST_DEPENDS:= ${RUN_DEPENDS} \ + ${PYTHON_PKGNAMEPREFIX}nose>0:${PORTSDIR}/devel/py-nose USE_GITHUB= yes GH_ACCOUNT= kennethreitz @@ -21,10 +23,10 @@ GH_TAGNAME= v${DISTVERSION} GH_COMMIT= aee3be6 USE_PYTHON= yes -USE_PYDISTUTILS= easy_install +USE_PYDISTUTILS= yes +PYDISTUTILS_AUTOPLIST= yes regression-test: build @cd ${WRKSRC} && ${PYTHON_CMD} ${PYSETUP} test -NO_STAGE= yes .include Modified: head/www/py-grequests/files/patch-setup.py ============================================================================== --- head/www/py-grequests/files/patch-setup.py Sun Feb 16 06:06:48 2014 (r344500) +++ head/www/py-grequests/files/patch-setup.py Sun Feb 16 07:01:03 2014 (r344501) @@ -1,10 +1,14 @@ ---- ./setup.py.orig 2013-03-05 10:04:42.000000000 +1100 -+++ ./setup.py 2013-04-29 20:25:38.800634016 +1000 -@@ -56,5 +56,6 @@ +# Support test command w/ tests_require & test_suite +# https://github.com/kennethreitz/grequests/pull/47 + +--- ./setup.py.orig 2014-02-16 17:35:13.772145487 +1100 ++++ ./setup.py 2014-02-16 17:36:15.191123632 +1100 +@@ -56,5 +56,7 @@ 'Programming Language :: Python', 'Topic :: Internet :: WWW/HTTP :: Dynamic Content', 'Topic :: Software Development :: Libraries :: Python Modules' - ] + ], -+ test_suite='tests' ++ tests_require = ['nose'], ++ test_suite = 'nose.collector', ) Added: head/www/py-grequests/files/patch-tests__test_grequests.py ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/www/py-grequests/files/patch-tests__test_grequests.py Sun Feb 16 07:01:03 2014 (r344501) @@ -0,0 +1,23 @@ +# Fix: request use **kwargs with its hooks. +# https://github.com/kennethreitz/grequests/commit/f50782ad63607b85e5e009f4a0a4ce0a8a6aef0d + +--- ./tests/test_grequests.py.orig 2014-02-16 17:23:40.926364751 +1100 ++++ ./tests/test_grequests.py 2014-02-16 17:24:14.491232949 +1100 +@@ -38,7 +38,7 @@ + def test_hooks(self): + result = {} + +- def hook(r): ++ def hook(r, **kwargs): + result[r.url] = True + return r + +@@ -49,7 +49,7 @@ + def test_callback_kwarg(self): + result = {'ok': False} + +- def callback(r): ++ def callback(r, **kwargs): + result['ok'] = True + return r +