-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #390 from JrGoodle/parallel-coverage
Add test coverage for parallel tests and write tests on Circle CI
- Loading branch information
Showing
26 changed files
with
195 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
# Python CircleCI 2.0 configuration file | ||
# | ||
# Check https://circleci.com/docs/2.0/language-python/ for more details | ||
# | ||
version: 2 | ||
jobs: | ||
build: | ||
docker: | ||
- image: circleci/python:3.6.1 | ||
|
||
working_directory: ~/clowder | ||
|
||
steps: | ||
- checkout | ||
|
||
# Download and cache dependencies | ||
- restore_cache: | ||
keys: | ||
- v1-dependencies-{{ checksum "clowder/requirements.txt" }} | ||
# fallback to using the latest cache if no exact match is found | ||
- v1-dependencies- | ||
|
||
- run: | ||
name: install dependencies | ||
command: | | ||
python3 -m venv venv | ||
. venv/bin/activate | ||
sudo pip install -r clowder/requirements.txt | ||
- run: | ||
name: run setup scripts | ||
command: | | ||
script/update | ||
script/test | ||
- save_cache: | ||
paths: | ||
- ./venv | ||
key: v1-dependencies-{{ checksum "clowder/requirements.txt" }} | ||
|
||
- add_ssh_keys: | ||
fingerprints: | ||
- "3a:38:b7:1e:b7:eb:c5:8f:4a:79:bd:4f:f0:9a:ea:61" | ||
|
||
- run: | ||
name: install git 2.13.6 | ||
command: | | ||
sudo apt-get remove git | ||
sudo apt-get update -y | ||
sudo apt-get install libcurl4-openssl-dev libexpat1-dev gettext libz-dev libssl-dev build-essential autoconf | ||
mkdir tmp-git-build | ||
pushd tmp-git-build | ||
curl -L --progress https://github.com/git/git/archive/v2.13.6.tar.gz | tar xz | ||
pushd git-2.13.6/ | ||
sudo make configure | ||
sudo ./configure | ||
sudo make prefix=/usr/local all | ||
sudo make prefix=/usr/local install | ||
popd | ||
popd | ||
- run: | ||
name: setup git config | ||
command: | | ||
git config --global user.email "circle@circleci.org" | ||
git config --global user.name "CircleCI" | ||
git config --global push.default simple | ||
- run: | ||
name: run write tests | ||
command: clowder-test -c write | ||
|
||
- run: | ||
name: upload code coverage results | ||
command: | | ||
coverage combine examples/cats examples/cocos2d-objc examples/llvm-projects examples/swift-projects | ||
codecov |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
argcomplete>=1.9.0 | ||
awscli>=1.11.186 | ||
cement>=2.10.2 | ||
codecov>=2.0.9 | ||
colorama>=0.3.9 | ||
coverage>=4.4.2 | ||
GitPython>=2.1.0 | ||
psutil>=5.4.0 | ||
PyYAML>=3.12 | ||
recommonmark>=0.4.0 | ||
sphinx>=1.6.5 | ||
sphinx-autobuild>=0.7.0 | ||
sphinx-rtd-theme>=0.2.4 | ||
termcolor>=1.1.0 | ||
psutil>=5.4.0 | ||
tqdm>=4.19.0 | ||
recommonmark>=0.4.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,8 @@ | ||
#!/usr/bin/env bash | ||
|
||
if [ "$TARGET" != "parallel" ]; then | ||
cd "$TRAVIS_BUILD_DIR" || exit 1 | ||
|
||
coverage combine examples/cats examples/cocos2d-objc examples/llvm-projects examples/swift-projects | ||
coverage xml | ||
./cc-test-reporter format-coverage --output "coverage/codeclimate.$TRAVIS_JOB_NUMBER.json" | ||
mv .coverage "coverage/.coverage.$TRAVIS_OS_NAME.$TARGET" | ||
aws s3 sync coverage/ "s3://clowder-coverage/coverage/$TRAVIS_BUILD_NUMBER" | ||
fi | ||
cd "$TRAVIS_BUILD_DIR" || exit 1 | ||
coverage combine examples/cats examples/cocos2d-objc examples/llvm-projects examples/swift-projects | ||
codecov | ||
./cc-test-reporter format-coverage --output "coverage/codeclimate.$TRAVIS_JOB_NUMBER.json" | ||
mv .coverage "coverage/.coverage.$TRAVIS_OS_NAME.$TARGET.$PYVERSION" | ||
aws s3 sync coverage/ "s3://clowder-coverage/coverage/$TRAVIS_BUILD_NUMBER" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
cd "$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/.." || exit 1 | ||
cd "$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/../.." || exit 1 | ||
|
||
if [ "$PYVERSION" == 'python2' ]; then | ||
PIP='pip' | ||
else | ||
PIP='pip3' | ||
fi | ||
|
||
if [ "$TRAVIS_OS_NAME" = "osx" ]; then | ||
brew install github-release | ||
sudo -H pip3 install twine wheel | ||
sudo -H $PIP install twine wheel | ||
fi | ||
|
||
if [ "$TARGET" != "parallel" ]; then | ||
sudo pip install awscli | ||
fi | ||
sudo $PIP install -r clowder/requirements.txt |
Oops, something went wrong.