1
0
mirror of https://github.com/webrecorder/pywb.git synced 2025-03-15 00:03:28 +01:00

added missing comma to setup.py's tests_require list

removed package.json from project as it is no longer required
removed npm install command from .travis/install.sh
This commit is contained in:
John Berlin 2019-09-04 13:41:56 -04:00
parent 8d98b9111e
commit 61b6ff21e1
No known key found for this signature in database
GPG Key ID: 6EF5E4B442011B02
3 changed files with 13 additions and 48 deletions

View File

@ -6,7 +6,6 @@ python setup.py -q install
pip install -r extra_requirements.txt
pip install coverage pytest-cov coveralls
pip install codecov
npm install
if [ "$WR_TEST" = "yes" ]; then
git clone https://github.com/webrecorder/webrecorder-tests.git

View File

@ -1,34 +0,0 @@
{
"name": "pywb",
"version": "1.0.0",
"description": "Web archival replay tools",
"main": "index.js",
"directories": {
"doc": "doc",
"test": "tests"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ikreymer/pywb.git"
},
"author": "",
"license": "GPL-3.0",
"bugs": {
"url": "https://github.com/ikreymer/pywb/issues"
},
"homepage": "https://github.com/ikreymer/pywb#readme",
"devDependencies": {
"chai": "^3.4.1",
"karma": "^0.13.15",
"karma-chai": "^0.1.0",
"karma-chrome-launcher": "^0.2.1",
"karma-firefox-launcher": "^0.1.7",
"karma-html2js-preprocessor": "^0.1.0",
"karma-mocha": "^0.2.1",
"karma-sauce-launcher": "^0.3.0",
"mocha": "^2.3.4"
}
}

View File

@ -18,12 +18,14 @@ def get_ldecription():
class PyTest(TestCommand):
user_options = []
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_suite = ' '
def run_tests(self):
from gevent.monkey import patch_all; patch_all()
from gevent.monkey import patch_all
patch_all()
import pytest
import os
@ -36,7 +38,6 @@ class PyTest(TestCommand):
sys.exit(errcode)
def get_git_short_hash():
import subprocess
try:
@ -45,19 +46,19 @@ def get_git_short_hash():
hash_id = hash_id.decode('utf-8')
return hash_id
except:
except Exception:
return ''
def generate_git_hash_py(pkg, filename='git_hash.py'):
try:
git_hash = get_git_short_hash()
with open(os.path.join(pkg, filename), 'wt') as fh:
fh.write('git_hash = "{0}"\n'.format(git_hash))
except:
except Exception:
pass
def load_requirements(filename):
with open(filename, 'rt') as fh:
requirements = fh.read().rstrip().split('\n')
@ -67,6 +68,7 @@ def load_requirements(filename):
requirements.append("pyAMF")
return requirements
def get_package_data():
pkgs = ['static/*.*',
'templates/*',
@ -79,10 +81,8 @@ def get_package_data():
return pkgs
generate_git_hash_py('pywb')
setup(
name='pywb',
version=__version__,
@ -96,7 +96,7 @@ setup(
zip_safe=True,
package_data={
'pywb': get_package_data(),
},
},
data_files=[
('sample_archive/cdx', glob.glob('sample_archive/cdx/*')),
('sample_archive/cdxj', glob.glob('sample_archive/cdxj/*')),
@ -104,8 +104,8 @@ setup(
('sample_archive/zipcdx', glob.glob('sample_archive/zipcdx/*')),
('sample_archive/warcs', glob.glob('sample_archive/warcs/*')),
('sample_archive/text_content',
glob.glob('sample_archive/text_content/*')),
],
glob.glob('sample_archive/text_content/*')),
],
install_requires=load_requirements('requirements.txt'),
tests_require=[
'pytest',
@ -116,9 +116,9 @@ setup(
'urllib3',
'werkzeug',
'httpbin==0.5.0',
'ujson'
'lxml',
],
'ujson',
'lxml'
],
cmdclass={'test': PyTest},
test_suite='',
entry_points="""