Skip to content

Commit 094dae6

Browse files
committed
Fixed circleci, added Flake8
1 parent 2e18bb8 commit 094dae6

File tree

4 files changed

+13
-3
lines changed

4 files changed

+13
-3
lines changed

.circleci/config.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,16 @@ jobs:
1212

1313
- run:
1414
name: Set PYTHONPATH environment variable
15-
command: echo 'export PYTHONPATH=${HOME}/app/mock:${HOME}/app/resources/lib:${HOME}/app/resources/connect' >> $BASH_ENV
15+
command: echo 'export PYTHONPATH=${HOME}/app/mock:${HOME}/app/resources/lib:${HOME}/app/resources' >> $BASH_ENV
1616

1717
- run:
1818
name: Export
1919
command: export
2020

21+
- run:
22+
name: Install Test dependencies
23+
command: sudo pip install pylint flake8
24+
2125
- run:
2226
name: Install dependencies
2327
command: ./install-dependencies.sh
@@ -32,4 +36,4 @@ jobs:
3236

3337
- run:
3438
name: Run tests
35-
command: python -m unittest discover -s resources/connect/tests/
39+
command: python -m unittest discover -s tests/

.flake8

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[flake8]
2+
max-line-length = 160
3+
ignore = E302,E305

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ ENV HOME=/home/python
44

55
RUN apt-get update && \
66
apt-get install -y zip && \
7-
pip install pylint && \
7+
pip install pylint flake8 && \
88
useradd -m python && \
99
mkdir -p $HOME/app && \
1010
chown -R python:python $HOME/app

run-linter.sh

+3
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,6 @@
22

33
pylint resources/connect service.py plugin.py
44
pylint --disable=duplicate-code,relative-import,invalid-name,protected-access tests/
5+
6+
flake8 --ignore=E402 service.py plugin.py
7+
flake8 resources/connect tests

0 commit comments

Comments
 (0)