

So you will have to add the path if you do otherwise. My project's manage.py is on the path (I install in the virtualenv bin via setup.py) opt/teamcity/virtualenvs/myproj/bin/activateĭropdb test_myproj-teamcity &> /dev/null # bug that is not destroying database

My build step that does the testing looks like this. # whatever special teamcity settings you might have go here If os.getenv('TEAMCITY_PROJECT_NAME') is not None: I use teamcity-nose with the following configuration in settings.py: TEST_RUNNER = 'django_nose.NoseTestSuiteRunner' htmlcov/index.html | grep '' | grep -o '\+') "context": "continuous-integration/coverage"Ĭoverage badge copy BADGE="/path/to/public/dir/badges/%%/%%-coverage.svg"

/repository/download/%%/.lastFinished/htmlcov/index.htmlįinally push GitHub hook to display build coverage state in repo:Ĭoverage Pending (before build) OWNER="".Īfter that, artifacts are collected in the TeamCity (tab General Settings) The cover_report command prints a cover report to the console, and also generates an html report and, using the coverage-badge utility, generates a beautiful badge with the badge code coverage status. The cover_test command runs the Django tests, and measures the coverage of the code. $(VENV_PATH)/coverage-badge > htmlcov/coverage.svg $(VENV_PATH)/coverage run -source=$(PROJ_NAME) manage.py test -v 2 -noinput A sought-after executive and keynote speaker on business leadership, Ed presents his theories on entrepreneurial spirit, vision, and drive through a multidisciplinary perspective of the world.In TeamCity I cover Django in the following wayĬreate coverage report by call make ci_test command use Makefile.

