Skip to content

Commit

Permalink
Add coveralls badge to README
Browse files Browse the repository at this point in the history
  • Loading branch information
bfbachmann committed Jun 25, 2018
1 parent 87e83d0 commit 1fd343c
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 8 deletions.
5 changes: 2 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ services:
install:
- make install-requirements
- make install-test-requirements
- pip install -e .
# Run tests and linters
script:
- make lint
- make docker-test
- make travis-test
- make clean
# Report code coverage after success
after_success: coveralls
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,14 @@ docker-test:
@docker-compose -f ${TEST} up -d postgres
@docker-compose -f ${TEST} run --rm web

# Run tests in Travis
.PHONY: travis-test
travis-test:
@docker-compose -f ${TEST} up -d postgres
@docker-compose -f ${TEST} run --rm -e TRAVIS_JOB_ID="${TRAVIS_JOB_ID}" \
-e TRAVIS_BRANCH="${TRAVIS_BRANCH}" -e COVERALLS_REPO_TOKEN="${COVERALLS_REPO_TOKEN}" \
--entrypoint bash web -c "coverage run --source=bounce -m pytest -v && coveralls"

# Clean up test containers
.PHONY: clean
clean:
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# :basketball: Bounce

[![Build Status](https://travis-ci.org/ubclaunchpad/bounce.svg?branch=master)](https://travis-ci.org/ubclaunchpad/bounce)
[![Coverage Status](https://coveralls.io/repos/github/ubclaunchpad/bounce/badge.svg)](https://coveralls.io/github/ubclaunchpad/bounce)

The backend for our application that brings people together based on common interests.

Expand Down
2 changes: 1 addition & 1 deletion container/test/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ RUN make install-requirements && make install-test-requirements
RUN pip install -e .

# Run tests
ENTRYPOINT [ "pytest", "-v", "--cov=bounce" ]
ENTRYPOINT [ "pytest", "-v" ]
1 change: 0 additions & 1 deletion test-requirements.in
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ yapf==0.22.0
isort==4.3.4
pytest-asyncio==0.8.0
aiohttp==3.3.0
pytest-cov==2.5.1
coveralls==1.3.0
5 changes: 2 additions & 3 deletions test-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ atomicwrites==1.1.5 # via pytest
attrs==18.1.0 # via aiohttp, pytest
certifi==2018.4.16 # via requests
chardet==3.0.4 # via aiohttp, requests
coverage==4.5.1 # via coveralls, pytest-cov
coverage==4.5.1 # via coveralls
coveralls==1.3.0
docopt==0.6.2 # via coveralls
flake8==3.5.0
Expand All @@ -28,8 +28,7 @@ pycodestyle==2.3.1 # via flake8
pyflakes==1.6.0 # via flake8
pylint==1.9.1
pytest-asyncio==0.8.0
pytest-cov==2.5.1
pytest==3.6.0 # via pytest-asyncio, pytest-cov
pytest==3.6.0 # via pytest-asyncio
requests==2.19.1 # via coveralls
six==1.11.0 # via astroid, more-itertools, pylint, pytest
urllib3==1.23 # via requests
Expand Down

0 comments on commit 1fd343c

Please sign in to comment.