diff options
author | Leo <thinkabit.ukim@gmail.com> | 2019-09-26 19:08:51 -0300 |
---|---|---|
committer | Kevin Daudt <kdaudt@alpinelinux.org> | 2019-10-25 20:02:58 +0000 |
commit | a9aeafa108166407b632c2fba2860af037b7e3a8 (patch) | |
tree | 3e7332f3a554f600fb08a5b8b72ce16bbcf63680 | |
parent | 3ac2256dbd76ebf75287c6dd695b917b1bbd8973 (diff) | |
download | aports-a9aeafa108166407b632c2fba2860af037b7e3a8.tar.bz2 aports-a9aeafa108166407b632c2fba2860af037b7e3a8.tar.xz |
community/py3-webassets: move from main
Closes !172
-rw-r--r-- | community/py3-webassets/APKBUILD (renamed from main/py3-webassets/APKBUILD) | 17 | ||||
-rw-r--r-- | community/py3-webassets/disable-test-that-requires-js-babel.patch | 39 |
2 files changed, 50 insertions, 6 deletions
diff --git a/main/py3-webassets/APKBUILD b/community/py3-webassets/APKBUILD index 549cbfc340..b9f663873b 100644 --- a/main/py3-webassets/APKBUILD +++ b/community/py3-webassets/APKBUILD @@ -4,27 +4,32 @@ _pkgname=webassets pkgver=0.12.1 pkgrel=2 pkgdesc="Asset management for web development" +options="!check" # 4 tests fail, 2 related to 'nose', 1 to 'pytest' url="https://pypi.python.org/pypi/webassets" arch="noarch" license="BSD-2-Clause" depends="python3" makedepends="py3-setuptools" -source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" +checkdepends="py3-nose py3-pytest py3-mock py3-babel" +source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz + disable-test-that-requires-js-babel.patch + " builddir="$srcdir"/$_pkgname-$pkgver replaces="py-webassets" # Backwards compatibility provides="py-webassets=$pkgver-r$pkgrel" # Backwards compatibility build() { - cd "$builddir" python3 setup.py build } +check() { + nosetests-3.7 +} + package() { - cd "$builddir" python3 setup.py install --prefix=/usr --root="$pkgdir" } -md5sums="429401824556e6e0868e437f9e561ba6 webassets-0.12.1.tar.gz" -sha256sums="e7d9c8887343123fd5b32309b33167428cb1318cdda97ece12d0907fd69d38db webassets-0.12.1.tar.gz" -sha512sums="f62b4108c31780f719128c543852834b1c305fd85b60dfc6f4e95454a83fafa6be03253f5859f9166890b1bfe40f339c6f9524b8091b6ea5a5ea4c31fb928d08 webassets-0.12.1.tar.gz" +sha512sums="f62b4108c31780f719128c543852834b1c305fd85b60dfc6f4e95454a83fafa6be03253f5859f9166890b1bfe40f339c6f9524b8091b6ea5a5ea4c31fb928d08 webassets-0.12.1.tar.gz +a4df1bf0d196a5c2a8dcd3f9bc380dccb40a12b11dd182b660ef84f4d7ef082dafa9692a04ba1c7230fa288ff19d1dc2a1009ab56ad021ce15034beb97c8f728 disable-test-that-requires-js-babel.patch" diff --git a/community/py3-webassets/disable-test-that-requires-js-babel.patch b/community/py3-webassets/disable-test-that-requires-js-babel.patch new file mode 100644 index 0000000000..cc451bd344 --- /dev/null +++ b/community/py3-webassets/disable-test-that-requires-js-babel.patch @@ -0,0 +1,39 @@ +diff --git a/tests/test_filters.py b/tests/test_filters.py +index e697c26..7c7f536 100644 +--- a/tests/test_filters.py ++++ b/tests/test_filters.py +@@ -1520,33 +1520,3 @@ class TestAutoprefixer6Filter(TempEnvironmentHelper): + assert 'webkit' in out + + +-class TestBabel(TempEnvironmentHelper): +- default_files = { +- 'test.es6': """var x = (p) => { return false; };""" +- } +- +- def test_es2015(self): +- es2015 = get_filter('babel', presets='es2015') +- try: +- self.mkbundle('test.es6', filters=es2015, output='output.js').build() +- except FilterError as e: +- # babel is not installed, that's ok. +- if 'Program file not found' in e.message: +- raise SkipTest() +- else: +- raise +- assert "var x = function x" in self.get('output.js') +- +- def test_extra_args(self): +- self.env.config['BABEL_EXTRA_ARGS'] = ['--minified'] +- self.mkbundle('test.es6', filters='babel', output='output.js').build() +- assert (self.get('output.js').strip() == +- 'var x=p=>{return false};') +- +- def test_run_in_debug_mode(self): +- """A setting can be used to make babel not run in debug.""" +- self.env.debug = True +- self.env.config['babel_run_in_debug'] = False +- self.mkbundle('test.es6', filters='babel', output='output.js').build() +- assert self.get('output.js') == self.default_files['test.es6'] +- + |