Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit23c9013

Browse files
committed
Update Travis to use tox, and add Appveyor CI
Update tox.ini to utilise requirements-test.txt, and run pylint.Require lxml 3.6.0 on Windows as it has wheels available for 2.6-3.4.Also enables coverage for PyPy on Travis.
1 parenta3022dc commit23c9013

7 files changed

+46
-30
lines changed

‎.appveyor.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# To activate, change the Appveyor settings to use `.appveyor.yml`.
2+
init:
3+
-SET PATH=C:\\Python27\\Scripts\\;%PATH%"
4+
-SET COVERAGE_RUN_OPTIONS="--parallel-mode"
5+
6+
install:
7+
-git submodule update --init --recursive
8+
-python -m pip install tox codecov
9+
10+
build:off
11+
12+
test_script:
13+
# Avoid py35-optional, as pypi does not have lxml wheels for py35
14+
-python -m tox -e "py35-base,{py26,py27,py33,py34}-{base,optional}"
15+
16+
on_success:
17+
-coverage combine
18+
-codecov

‎.pylintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ ignore=tests
33

44
[MESSAGES CONTROL]
55
# messages up to fixme should probably be fixed somehow
6-
disable = redefined-builtin,attribute-defined-outside-init,anomalous-backslash-in-string,no-self-use,redefined-outer-name,bad-continuation,wrong-import-order,superfluous-parens,no-member,duplicate-code,super-init-not-called,abstract-method,property-on-old-class,wrong-import-position,no-name-in-module,no-init,bad-mcs-classmethod-argument,bad-classmethod-argument,fixme,invalid-name,import-error,too-few-public-methods,too-many-ancestors,too-many-arguments,too-many-boolean-expressions,too-many-branches,too-many-instance-attributes,too-many-locals,too-many-lines,too-many-public-methods,too-many-return-statements,too-many-statements,missing-docstring,line-too-long,locally-disabled,locally-enabled,bad-builtin,deprecated-lambda
6+
disable = redefined-builtin,attribute-defined-outside-init,anomalous-backslash-in-string,no-self-use,redefined-outer-name,bad-continuation,wrong-import-order,superfluous-parens,no-member,duplicate-code,super-init-not-called,abstract-method,property-on-old-class,wrong-import-position,no-name-in-module,no-init,bad-mcs-classmethod-argument,bad-classmethod-argument,fixme,invalid-name,import-error,too-few-public-methods,too-many-ancestors,too-many-arguments,too-many-boolean-expressions,too-many-branches,too-many-instance-attributes,too-many-locals,too-many-lines,too-many-public-methods,too-many-return-statements,too-many-statements,missing-docstring,line-too-long,locally-disabled,locally-enabled,bad-builtin,deprecated-lambda,bad-option-value,star-args,abstract-class-little-used,abstract-class-not-used
77

88
[FORMAT]
99
max-line-length=139

‎.travis.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,22 +14,17 @@ cache:
1414
-$HOME/.cache/pip
1515

1616
env:
17-
-USE_OPTIONAL=true
18-
-USE_OPTIONAL=false
19-
20-
before_install:
21-
-git submodule update --init --recursive
17+
-TOXENV=optional
18+
-TOXENV=base
2219

2320
install:
24-
-bash requirements-install.sh
21+
-pipinstall tox codecov
2522

2623
script:
27-
-if [[ $TRAVIS_PYTHON_VERSION == pypy* ]]; then py.test; fi
28-
-if [[ $TRAVIS_PYTHON_VERSION != pypy* ]]; then coverage run -m pytest; fi
29-
-bash flake8-run.sh
24+
-tox
3025

3126
after_script:
3227
-python debug-info.py
3328

3429
after_success:
35-
-if [[ $TRAVIS_PYTHON_VERSION != pypy* ]]; then coverage combine &&codecov; fi
30+
-codecov

‎flake8-run.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

‎requirements-optional.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@ chardet>=2.2
1010

1111
# lxml is supported with its own treebuilder ("lxml") and otherwise
1212
# uses the standard ElementTree support
13-
lxml ; platform_python_implementation == 'CPython'
13+
lxml ; platform_python_implementation == 'CPython' and sys_platform != 'win32'
14+
lxml==3.6.0 ; platform_python_implementation == 'CPython' and sys_platform == 'win32' and python_version <= '3.4'
15+
lxml==3.6.0 ; platform_python_implementation == 'CPython' and sys_platform == 'win_amd64' and python_version <= '3.4'
16+
lxml ; platform_python_implementation == 'CPython' and sys_platform == 'win32' and python_version >= '3.5'
17+
lxml ; platform_python_implementation == 'CPython' and sys_platform == 'win_amd64' and python_version >= '3.5'
1418

1519
# DATrie can be used in place of our Python trie implementation for
1620
# slightly better parsing performance.

‎requirements-test.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
-r requirements.txt
22

3+
tox
4+
35
flake8<3.0
6+
7+
pylint==1.6.4 ; python_version > '2.6'
8+
pylint==1.3.1 ; python_version <= '2.6'
9+
astroid==1.3.5 ; python_version <= '2.6'
10+
411
pytest
12+
coverage
513
pytest-expect>=1.1,<2.0
614
mock

‎tox.ini

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ envlist = {py26,py27,py33,py34,py35,pypy}-{base,optional}
33

44
[testenv]
55
deps =
6-
flake8<3.0
7-
pytest
8-
pytest-expect>=1.1,<2.0
9-
mock
10-
base: six
11-
base: webencodings
12-
py26-base: ordereddict
6+
-r{toxinidir}/requirements-test.txt
137
optional: -r{toxinidir}/requirements-optional.txt
148

9+
passenv =
10+
COVERAGE_RUN_OPTIONS
1511
commands =
16-
{envbindir}/py.test
17-
{toxinidir}/flake8-run.sh
12+
coverage run {env:COVERAGE_RUN_OPTIONS:} -m pytest
13+
flake8
14+
pylint --rcfile={toxinidir}/.pylintrc html5lib
15+
16+
[flake8]
17+
exclude = ./.tox

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp