Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
7ef2781c
Kaydet (Commit)
7ef2781c
authored
Eki 11, 2012
tarafından
Tim Graham
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #4501 - Documented how to use coverage.py with Django tests.
Thanks krzysiumed for the draft patch.
üst
f7b69665
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
0 deletions
+28
-0
testing.txt
docs/topics/testing.txt
+28
-0
No files found.
docs/topics/testing.txt
Dosyayı görüntüle @
7ef2781c
...
...
@@ -589,6 +589,34 @@ to a faster hashing algorithm::
Don't forget to also include in :setting:`PASSWORD_HASHERS` any hashing
algorithm used in fixtures, if any.
Integration with coverage.py
----------------------------
Code coverage describes how much source code has been tested. It shows which
parts of your code are being exercised by tests and which are not. It's an
important part of testing applications, so it's strongly recommended to check
the coverage of your tests.
Django can be easily integrated with `coverage.py`_, a tool for measuring code
coverage of Python programs. First, `install coverage.py`_. Next, run the
following from your project folder containing ``manage.py``::
coverage run --source='.' manage.py test myapp
This runs your tests and collects coverage data of the executed files in your
project. You can see a report of this data by typing following command::
coverage report
Note that some Django code was executed while running tests, but it is not
listed here because of the ``source`` flag passed to the previous command.
For more options like annotated HTML listings detailing missed lines, see the
`coverage.py`_ docs.
.. _coverage.py: http://nedbatchelder.com/code/coverage/
.. _install coverage.py: http://pypi.python.org/pypi/coverage
Testing tools
=============
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment