Skip to content

Commit 68a6661

Browse files
committed
updated badges
1 parent d2e6905 commit 68a6661

File tree

4 files changed

+51
-30
lines changed

4 files changed

+51
-30
lines changed

.travis.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,15 @@
1-
language: python
1+
language:
2+
- python
3+
24
python:
35
- "2.7.6"
6+
47
before_script:
5-
# Install Testspace Runner
6-
- ./testspace_install.sh
7-
- export PATH="${HOME}/testspace:${PATH}"
88
- sudo pip install -r requirements.txt
9+
910
script:
1011
- nose2 -X -C --coverage-report xml
11-
12-
# Publish Test Results along with Coverage
13-
- testspace publish [Tests]nose2.xml coverage.xml ${TESTSPACE_URL}
12+
13+
after_script:
14+
- 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}

README.md

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,22 @@
55

66
Sample demonstrates techniques for using Testspace with Python code and the [`unittest` test framework](https://docs.python.org/2/library/unittest.html) together with [`cov-core` code coverage tool](https://pypi.python.org/pypi/cov-core) and [`nose2` runner](https://github.com/nose-devs/nose2).
77

8-
[![Build Status](https://travis-ci.org/testspace-samples/python.unittest.svg?branch=master)](https://travis-ci.org/testspace-samples/python.unittest)
9-
[![Space Health](https://samples.testspace.com/projects/91/spaces/310/badge)](https://samples.testspace.com/projects/91/spaces/310 "Test Cases")
10-
[![Space Metric](https://samples.testspace.com/projects/91/spaces/310/metrics/209/badge)](https://samples.testspace.com/projects/91/spaces/310/metrics#metric-209 "Line/Statement Coverage")
8+
***
9+
Using Multiple Online CI Services:
10+
11+
[![Build Status](https://travis-ci.org/testspace-samples/php.phpunit.svg?branch=master)](https://travis-ci.org/testspace-samples/php.phpunit)
12+
[![CircleCI](https://circleci.com/gh/testspace-samples/python.unittest.svg?style=svg)](https://circleci.com/gh/testspace-samples/python.unittest)
13+
[![Run Status](https://api.shippable.com/projects/5710a3e02a8192902e1c1f8d/badge?branch=master)](https://app.shippable.com/projects/5710a3e02a8192902e1c1f8d)
14+
1115

1216
***
17+
Publishing **Test Content** using www.testspace.com.
18+
19+
[![Space Health](https://samples.testspace.com/projects/120/spaces/444/badge)](https://samples.testspace.com/projects/120/spaces/444 "Test Cases")
20+
[![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+
22+
23+
***
1324

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

@@ -18,20 +29,18 @@ sudo pip install -r requirements.txt
1829
nose2 --junit-xml --with-coverage --coverage-report xml
1930
</pre>
2031

21-
Publishing results example:
32+
Publishing Results using **Testspace**:
2233

2334
<pre>
24-
testspace publish [Tests]nose2.xml coverage.xml
35+
testspace [Tests]nose2.xml coverage.xml $TESTSPACE_TOKEN/$BRANCH_NAME
2536
</pre>
2637

27-
Checkout the [Space](https://samples.testspace.com/projects/python/spaces/unittest).
38+
Checkout the [Space](https://samples.testspace.com/projects/python.unittest).
2839

2940
***
30-
31-
To fork this example using Travis requires:
41+
To replicate this sample:
3242
- Account at www.testspace.com.
33-
- Travis Environment Variable:
34-
- `TESTSPACE_URL` = `credentials:@my-org-name.testspace.com/my-project/my-space`
43+
- CI Environment Variable called **TESTSPACE_TOKEN** required:
44+
- `TESTSPACE_TOKEN` = `[email protected]/my-project`
3545
- `credentials` set to `username:password` or your [access token](http://help.testspace.com/using-your-organization:user-settings).
36-
- `my-org-name.testspace.com/my-project/my-space` based on your subdomain, project, and space names. Refer [here](http://help.testspace.com/reference:runner-reference#login-credentials) for more details.
37-
46+
- `my-org-name.testspace.com/my-project` based on your *subdomain* and *project* names. Refer [here](http://help.testspace.com/reference:runner-reference#login-credentials) for more details.

circle.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
machine:
2+
python:
3+
version: 2.7.6
4+
5+
dependencies:
6+
override:
7+
- sudo pip install -r requirements.txt
8+
test:
9+
override:
10+
- nose2 -X -C --coverage-report xml
11+
12+
post:
13+
- 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}

shippable.yml

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,14 @@ python:
55

66
env:
77
global:
8-
- secure: FoXq63ka7EuWlqxNTG1RJqTCCzng5/FQXJkjjXarT5Rc4vxZv/1S6f+aRrYUz4Vz/i6H23/7iPDjE8qxN0sQdtfw6r5kvj5vc5LRdv3cB+h1DzVclqHcukXiuHnDJgmSnfY/KLRROPOTGFnSPPJmxE4L3CIZCJsMZOykOqikqD/ts8X2qpzNQluaL7N8Cmnks24dDSdqI7uad35bjwHY74u/TbWrjrSfQNZJYoGGg4TCHjb/m2b41op0apOa0pG3SO4HgodBeo1OsndWg9fDwlyIVhh+otDkuCcI1m7RvNATY9I17sN5a6iUN6UMgBHEEq2GS7aRcDZ0mTBsNzKaoQ==
9-
8+
- secure: RGODsZdmwQ3s4UWceX5G38WaPZSMwqVYpfhIzni6QqhK+/oaB01qfkcoe79MwI2z2FVo68+mH+oYhcwhc9KSWal7O7FQshZPS8m0e5TIX3FzaD+KYzON/YYWRXdye9F/4DgtCSKrObkCIl0jJkAHkjITq4kU/FSWMGsUeqyjSPjNLPqOlp5KgNe+CKKGhKddCGH/KSLKfc0zMEgMLKHRmSLh5narSX0raNkxierBY3IV/l8X0QWaSo+eunztKU6yCvQLXOKoJ3Ej+yzNvjWdUtIEndUqwKdytxF0pb0eY9IoYOicfn9uDn4T9oymQMqjkoPpGf30AyBaW/XfCyOFFQ==
9+
1010
before_script:
11-
- ./testspace_install.sh
12-
- export PATH="${HOME}/testspace:${PATH}"
13-
- mkdir -p shippable/codecoverage
14-
- mkdir -p shippable/testresults
15-
11+
- sudo pip install -r requirements.txt
12+
1613
script:
17-
- testspace import .testspace.xml ${TESTSPACE_URL}
18-
- testspace run ${TESTSPACE_URL}
14+
- nose2 -X -C --coverage-report xml
1915

2016
after_script:
21-
- cp nose2.xml shippable/testresults
22-
- cp coverage.xml shippable/codecoverage
17+
- 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}

0 commit comments

Comments
 (0)