add CircleCI
This commit is contained in:
parent
632d07b490
commit
4e0b9c50e7
|
@ -0,0 +1,60 @@
|
|||
version: 2.0
|
||||
|
||||
references:
|
||||
|
||||
install_pips: &install_pips
|
||||
run:
|
||||
name: Install PyPI dependences
|
||||
command: |
|
||||
pip install -r requirements.txt --user
|
||||
sudo pip install -r ./tests/requirements.txt
|
||||
python --version ; pwd ; ls -l
|
||||
pip --version ; pip list
|
||||
|
||||
test_coverage: &test_coverage
|
||||
run:
|
||||
name: Testing and Formating
|
||||
command: |
|
||||
check-manifest --ignore tox.ini
|
||||
python setup.py check -m -s
|
||||
coverage run --source pytorch_lightning -m py.test pytorch_lightning tests examples -v --doctest-modules
|
||||
flake8 . --max-line-length=100
|
||||
codecov
|
||||
|
||||
jobs:
|
||||
|
||||
Py3.6:
|
||||
docker:
|
||||
- image: circleci/python:3.6
|
||||
steps: &steps
|
||||
- checkout
|
||||
# INSTALLATION
|
||||
- *install_pips
|
||||
# TESTING
|
||||
- *test_coverage
|
||||
# DOCUMENTATION
|
||||
|
||||
# PASSING
|
||||
- run:
|
||||
name: Finalise
|
||||
command: |
|
||||
python setup.py install --user
|
||||
coverage report && coverage xml -o test-reports/coverage.xml
|
||||
# RESULTS
|
||||
- store_test_results:
|
||||
path: test-reports
|
||||
- store_artifacts:
|
||||
path: test-reports
|
||||
|
||||
Py3.7:
|
||||
docker:
|
||||
- image: circleci/python:3.7
|
||||
steps: *steps
|
||||
|
||||
|
||||
workflows:
|
||||
version: 2
|
||||
build:
|
||||
jobs:
|
||||
- Py3.6
|
||||
- Py3.7
|
|
@ -31,7 +31,6 @@ cache: pip
|
|||
install:
|
||||
- pip install -r requirements.txt
|
||||
- pip install -r ./tests/requirements.txt
|
||||
- pip install tox
|
||||
- pip --version ; pip list
|
||||
|
||||
script:
|
||||
|
|
|
@ -27,10 +27,12 @@ exclude docs
|
|||
include requirements.txt
|
||||
|
||||
# Exclude build configs
|
||||
recursive-exclude .circleci *
|
||||
exclude *.yml
|
||||
|
||||
prune .git
|
||||
prune .github
|
||||
prune .circleci
|
||||
prune notebook*
|
||||
prune temp*
|
||||
prune test*
|
|
@ -45,7 +45,6 @@ install:
|
|||
- pip install -U --user pip
|
||||
- pip install -r requirements.txt
|
||||
- pip install -r ./tests/requirements.txt
|
||||
- pip install tox
|
||||
|
||||
# scripts to run before tests (working directory and environment changes are persisted from the previous steps such as "before_build")
|
||||
before_test:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
nose>=1.3.7
|
||||
tox
|
||||
coverage
|
||||
codecov
|
||||
pytest>=3.0.5
|
||||
|
|
3
tox.ini
3
tox.ini
|
@ -43,8 +43,5 @@ select = E,W,F
|
|||
doctests = True
|
||||
verbose = 2
|
||||
# https://pep8.readthedocs.io/en/latest/intro.html#error-codes
|
||||
ignore =
|
||||
E402
|
||||
E501
|
||||
format = pylint
|
||||
max-line-length = 100
|
||||
|
|
Loading…
Reference in New Issue