Skip to content

Commit bcc7b74

Browse files
committed
adding circle ci
1 parent f52fee0 commit bcc7b74

File tree

3 files changed

+40
-7
lines changed

3 files changed

+40
-7
lines changed

.gitignore

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33

44
# But not these files
55
!.gitignore
6-
!.travis.yml
6+
77
!LICENSE
88
!README.md
9-
!testspace_install.sh
10-
!.testspace.xml
11-
!shippable.yml
129

10+
!.travis.yml
11+
!shippable.yml
12+
!circle.yml
1313
!.c9build.sh

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ Sample demonstrates techniques for using Testspace with C++ code and the [Google
99
Using Multiple Online CI Services:
1010

1111
[![Build Status](https://travis-ci.org/testspace-samples/cpp.googletest.svg?branch=master)](https://travis-ci.org/testspace-samples/cpp.googletest)
12+
[![CircleCI](https://circleci.com/gh/testspace-samples/cpp.googletest.svg?style=svg)](https://circleci.com/gh/testspace-samples/cpp.googletest)
1213
[![Run Status](https://api.shippable.com/projects/570008739d043da07b099664/badge?branch=master)](https://app.shippable.com/projects/570008739d043da07b099664)
1314

1415

@@ -57,6 +58,5 @@ To replicate this sample:
5758
- Account at www.testspace.com.
5859
- CI Environment Variable called **TESTSPACE_TOKEN** required:
5960
- `TESTSPACE_TOKEN` = `[email protected]/my-project`
60-
- `credentials` set to `username:password` or your [access token](http://help.testspace.com/using-your-organization:user-settings).
61-
- `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.
62-
61+
- `credentials` set to `username:password` or your [access token](http://help.testspace.com/reference:client-reference#login-credentials).
62+
- `my-org-name.testspace.com/my-project` based on your *organization* (subdomain) and *project* names.

circle.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
dependencies:
2+
pre:
3+
- sudo apt-get update
4+
- sudo apt-get install cmake
5+
- sudo pip install gcovr
6+
- wget https://github.com/google/googletest/archive/release-1.7.0.zip
7+
- unzip release-1.7.0.zip
8+
- mv googletest-release-1.7.0 gtest
9+
override:
10+
- cd gtest
11+
- mkdir build
12+
- cd build
13+
- cmake -Dgtest_build_samples=ON -DCMAKE_BUILD_TYPE=Debug -DCMAKE_CXX_FLAGS_DEBUG='-g -fprofile-arcs -ftest-coverage' ../
14+
15+
test:
16+
override:
17+
- make
18+
- ./sample1_unittest --gtest_output=xml:sample1.xml
19+
- ./sample2_unittest --gtest_output=xml:sample2.xml
20+
- ./sample3_unittest --gtest_output=xml:sample3.xml
21+
- ./sample4_unittest --gtest_output=xml:sample4.xml
22+
- ./sample5_unittest --gtest_output=xml:sample5.xml
23+
- ./sample6_unittest --gtest_output=xml:sample6.xml
24+
- ./sample7_unittest --gtest_output=xml:sample7.xml
25+
- ./sample8_unittest --gtest_output=xml:sample8.xml
26+
- ./sample9_unittest --gtest_output=xml:sample9.xml
27+
- ./sample10_unittest --gtest_output=xml:sample10.xml
28+
- cd ..
29+
- gcovr --root $PWD --filter ".*/samples.*" --exclude ".*_unittest.*" -x -o build/coverage.xml
30+
post:
31+
- curl -s https://testspace-client.s3.amazonaws.com/testspace-linux.tgz | sudo tar -zxvf- -C /usr/local/bin
32+
- cd build
33+
- testspace [Tests]sample*.xml coverage.xml $TESTSPACE_TOKEN/${CIRCLE_BRANCH}#circle.Build.${CIRCLE_BUILD_NUM}

0 commit comments

Comments
 (0)