File tree Expand file tree Collapse file tree 5 files changed +32
-7
lines changed
Expand file tree Collapse file tree 5 files changed +32
-7
lines changed Original file line number Diff line number Diff line change 22
33# Build
44sudo 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
1011nose2 --junit-xml --with-coverage --coverage-report xml
1112
1213# Publish
1314curl -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
Original file line number Diff line number Diff line change @@ -6,10 +6,13 @@ python:
66
77before_script :
88 - sudo pip install -r requirements.txt
9+ - sudo apt-get install pylint
910
1011script :
12+ - pylint stock_alerter/ -f parseable > analysis.txt
1113 - nose2 -X -C --coverage-report xml
1214
1315after_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+
Original file line number Diff line number Diff 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
2526In order to run this sample you will need a host workstation with installed python 2.6+.
2627
28+ Buiding:
29+
2730<pre >
2831sudo 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+
3248Publishing 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
3854Checkout the [ Space] ( https://samples.testspace.com/projects/python.unittest ) .
Original file line number Diff line number Diff line change @@ -5,10 +5,13 @@ machine:
55dependencies :
66 override :
77 - sudo pip install -r requirements.txt
8+ - sudo apt-get install pylint
9+
810test :
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}
Original file line number Diff line number Diff line change 99
1010before_script :
1111 - sudo pip install -r requirements.txt
12+ - sudo apt-get install pylint
1213
1314script :
15+ - pylint stock_alerter/ -f parseable > analysis.txt
1416 - nose2 -X -C --coverage-report xml
1517
1618after_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}
You can’t perform that action at this time.
0 commit comments