-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
1,082 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
# Python CircleCI 2.1 configuration file | ||
version: 2.1 | ||
|
||
orbs: | ||
codecov: codecov/codecov@1.0.2 | ||
|
||
jobs: | ||
py37: &test-template | ||
docker: | ||
- image: circleci/python:3.7 | ||
|
||
working_directory: ~/repo | ||
|
||
parameters: | ||
is-py27: | ||
type: boolean | ||
default: false | ||
|
||
steps: | ||
- run: | ||
name: Install telnet | ||
command: | | ||
sudo apt-get update && sudo apt-get install telnet | ||
- checkout | ||
|
||
- when: | ||
condition: <<parameters.is-py27>> | ||
steps: | ||
- run: | ||
name: Create virtual env in PY2 | ||
command: | | ||
virtualenv ./venv | ||
- unless: | ||
condition: <<parameters.is-py27>> | ||
steps: | ||
- run: | ||
name: Create virtual env in PY3 | ||
command: | | ||
python3 -m venv venv | ||
- run: | ||
name: Install dependencies | ||
command: | | ||
# python3 -m venv venv | ||
# virtualenv ./venv | ||
. venv/bin/activate | ||
which python | ||
python --version | ||
pip install -r requirements.txt | ||
pip install -r requirements-tests.txt | ||
- run: | ||
name: Run tests | ||
command: | | ||
. venv/bin/activate | ||
# flake8 --exclude=venv* --statistics | ||
coverage erase | ||
coverage run --source=logparser -m pytest tests -s -vv -l --disable-warnings | ||
coverage report | ||
coverage html | ||
coverage xml | ||
coveralls | ||
ls -la | ||
- store_artifacts: | ||
path: htmlcov | ||
- store_artifacts: | ||
path: coverage.xml | ||
- codecov/upload: | ||
file: coverage.xml | ||
|
||
py27: | ||
<<: *test-template | ||
docker: | ||
- image: circleci/python:2.7 | ||
|
||
py35: | ||
<<: *test-template | ||
docker: | ||
- image: circleci/python:3.5 | ||
|
||
py36: | ||
<<: *test-template | ||
docker: | ||
- image: circleci/python:3.6 | ||
|
||
workflows: | ||
test: | ||
jobs: | ||
- py27: | ||
is-py27: true | ||
- py35 | ||
- py36 | ||
- py37 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
codecov: | ||
notify: | ||
require_ci_to_pass: yes | ||
|
||
coverage: | ||
precision: 2 | ||
round: down | ||
range: "70...100" | ||
|
||
status: | ||
project: yes | ||
patch: yes | ||
changes: no | ||
|
||
parsers: | ||
gcov: | ||
branch_detection: | ||
conditional: yes | ||
loop: yes | ||
method: no | ||
macro: no | ||
|
||
comment: | ||
layout: "header, reach, diff, flags, files" | ||
behavior: default | ||
require_changes: no |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[run] | ||
include = logparser/* |
Oops, something went wrong.