Skip to content

Commit 6d65648

Browse files
committed
added pylint
1 parent 712d9f6 commit 6d65648

File tree

5 files changed

+32
-7
lines changed

5 files changed

+32
-7
lines changed

.c9build.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22

33
# Build
44
sudo pip install -r requirements.txt
5+
sudo apt-get install pylint
56

67
# Code Analysis
7-
8+
pylint stock_alerter/ -f parseable > analysis.txt
89

910
# Test with Code Coverage
1011
nose2 --junit-xml --with-coverage --coverage-report xml
1112

1213
# Publish
1314
curl -s https://testspace-client.s3.amazonaws.com/testspace-linux.tgz | sudo tar -zxvf- -C /usr/local/bin
14-
testspace publish [Tests]nose2.xml coverage.xml master.c9
15+
testspace analysis.txt{issues} [Tests]nose2.xml{stock_alerter} coverage.xml master.c9

.travis.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,13 @@ python:
66

77
before_script:
88
- sudo pip install -r requirements.txt
9+
- sudo apt-get install pylint
910

1011
script:
12+
- pylint stock_alerter/ -f parseable > analysis.txt
1113
- nose2 -X -C --coverage-report xml
1214

1315
after_script:
1416
- curl -s https://testspace-client.s3.amazonaws.com/testspace-linux.tgz | sudo tar -zxvf- -C /usr/local/bin
15-
- testspace publish [Tests]nose2.xml coverage.xml $TESTSPACE_TOKEN/${TRAVIS_BRANCH}#travis.Build.${TRAVIS_BUILD_NUMBER}
17+
- testspace analysis.txt{issues} [Tests]nose2.xml{stock_alerter} coverage.xml $TESTSPACE_TOKEN/${TRAVIS_BRANCH}#travis.Build.${TRAVIS_BUILD_NUMBER}
18+

README.md

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,21 +18,37 @@ Publishing **Test Content** using www.testspace.com.
1818

1919
[![Space Health](https://samples.testspace.com/projects/120/spaces/444/badge)](https://samples.testspace.com/projects/120/spaces/444 "Test Cases")
2020
[![Space Metric](https://samples.testspace.com/projects/120/spaces/444/metrics/272/badge)](https://samples.testspace.com/spaces/444/schema/Code%20Coverage "Code Coverage (lines)")
21+
[![Space Metric](https://samples.testspace.com/projects/120/spaces/444/metrics/274/badge)](https://samples.testspace.com/spaces/444/schema/Static%20Analysis "Static Analysis (issues)")
2122

2223

2324
***
2425

2526
In order to run this sample you will need a host workstation with installed python 2.6+.
2627

28+
Buiding:
29+
2730
<pre>
2831
sudo pip install -r requirements.txt
29-
nose2 --junit-xml --with-coverage --coverage-report xml
32+
sudo apt-get install pylint
3033
</pre>
3134

35+
36+
Running Static Analysis:
37+
<pre>
38+
nose2 --junit-xml --with-coverage --coverage-report xml
39+
</pre>
40+
41+
Running Tests with Code Coverage:
42+
43+
<pre>
44+
nose2 --junit-xml --with-coverage --coverage-report xml
45+
</pre>
46+
47+
3248
Publishing Results using **Testspace**:
3349

3450
<pre>
35-
testspace [Tests]nose2.xml coverage.xml $TESTSPACE_TOKEN/$BRANCH_NAME
51+
testspace analysis.txt{issues} [Tests]nose2.xml{stock_alerter} coverage.xml $TESTSPACE_TOKEN/$BRANCH_NAME
3652
</pre>
3753

3854
Checkout the [Space](https://samples.testspace.com/projects/python.unittest).

circle.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,13 @@ machine:
55
dependencies:
66
override:
77
- sudo pip install -r requirements.txt
8+
- sudo apt-get install pylint
9+
810
test:
911
override:
12+
- pylint stock_alerter/ -f parseable > analysis.txt
1013
- nose2 -X -C --coverage-report xml
1114

1215
post:
1316
- curl -s https://testspace-client.s3.amazonaws.com/testspace-linux.tgz | sudo tar -zxvf- -C /usr/local/bin
14-
- testspace publish [Tests]nose2.xml coverage.xml $TESTSPACE_TOKEN/${CIRCLE_BRANCH}#circle.Build.${CIRCLE_BUILD_NUM}
17+
- testspace analysis.txt{issues} [Tests]nose2.xml{stock_alerter} coverage.xml $TESTSPACE_TOKEN/${CIRCLE_BRANCH}#circle.Build.${CIRCLE_BUILD_NUM}

shippable.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@ env:
99

1010
before_script:
1111
- sudo pip install -r requirements.txt
12+
- sudo apt-get install pylint
1213

1314
script:
15+
- pylint stock_alerter/ -f parseable > analysis.txt
1416
- nose2 -X -C --coverage-report xml
1517

1618
after_script:
1719
- curl -s https://testspace-client.s3.amazonaws.com/testspace-linux.tgz | sudo tar -zxvf- -C /usr/local/bin
18-
- testspace publish [Tests]nose2.xml coverage.xml $TESTSPACE_TOKEN/${BRANCH}#ship.Build.${BUILD_NUMBER}
20+
- testspace analysis.txt{issues} [Tests]nose2.xml{stock_alerter} coverage.xml $TESTSPACE_TOKEN/${BRANCH}#ship.Build.${BUILD_NUMBER}

0 commit comments

Comments
 (0)