[26155] in CVS-changelog-for-Kerberos-V5
svn rev #25495: trunk/doc/rst_source/krb_build/
daemon@ATHENA.MIT.EDU (tsitkova@mit.edu)
Wed Nov 30 17:28:45 2011
Date: Wed, 30 Nov 2011 17:28:43 -0500
From: tsitkova@mit.edu
Message-Id: <201111302228.pAUMShYH030644@drugstore.mit.edu>
To: cvs-krb5@mit.edu
Reply-To: krbdev@mit.edu
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: cvs-krb5-bounces@mit.edu
http://src.mit.edu/fisheye/changelog/krb5/?cs=25495
Commit By: tsitkova
Log Message:
Added Test Coverage topic
Changed Files:
U trunk/doc/rst_source/krb_build/index.rst
A trunk/doc/rst_source/krb_build/test_cov.rst
Modified: trunk/doc/rst_source/krb_build/index.rst
===================================================================
--- trunk/doc/rst_source/krb_build/index.rst 2011-11-29 23:11:13 UTC (rev 25494)
+++ trunk/doc/rst_source/krb_build/index.rst 2011-11-30 22:28:43 UTC (rev 25495)
@@ -46,6 +46,7 @@
doing_build.rst
options2configure.rst
osconf.rst
+ test_cov.rst
Added: trunk/doc/rst_source/krb_build/test_cov.rst
===================================================================
--- trunk/doc/rst_source/krb_build/test_cov.rst (rev 0)
+++ trunk/doc/rst_source/krb_build/test_cov.rst 2011-11-30 22:28:43 UTC (rev 25495)
@@ -0,0 +1,33 @@
+
+Test coverage
+=================
+
+It is considered good practice to develop and maintain the test suite with high level
+of test coverage, i.e. the tests that execute every single statement, every line of the code and
+then validate the result.
+
+The GNU's *gcov* is a tool that analyses the frequency of execution of each line of the code.
+For more details see GNU documentation http://gcc.gnu.org/onlinedocs/gcc/Gcov.html
+
+To invoke *gcov* on *krb5* tree, do *configure* with the following options and run the tests::
+
+ ./configure CFLAGS="-fprofile-arcs -ftest-coverage -O0" LIBS=-lgcov
+ make
+ make check
+
+It will result into creation of the new helper files with the extentions *gcno* and *gcda*.
+
+To validate the test coverage of the specific file, change the directory to
+its location and run ::
+
+ gcov -o filename.so.gcno filename.c
+
+To see the test coverage of the *filename.c* open a newly created file *filename.c.gcov* in the editor.
+
+Some recent test coverage result can be found at the http://k5wiki.kerberos.org/wiki/Test_coverage
+
+
+
+
+
+
_______________________________________________
cvs-krb5 mailing list
cvs-krb5@mit.edu
https://mailman.mit.edu/mailman/listinfo/cvs-krb5