libgit2/tests
Carlos Martín Nieto bb0757d56c tree-cache: correct the entry_count calculation
The entry_count field is the amount of index entries covered by a
particular cache entry, that is how many files are there (recursively)
under a particular directory.

The current code that attemps to do this is severely defincient and is
trying to count the amount of children, which always comes up to zero.

We don't even need to recount, since we have the information during the
cache creation. We can take that number and keep it, as we only ever
invalidate or replace.
2014-10-22 21:25:08 +02:00
..
attr attr: Add an extra test for files under a subfolder 2014-09-17 15:08:16 +02:00
blame Factor 40 and 41 constants from source. 2014-09-16 13:07:04 +02:00
buf
checkout Introduce failing test for conflict filtering in index 2014-10-13 13:36:16 -04:00
cherrypick Fix test build 2014-10-10 18:03:09 +02:00
clar
clone
commit
config config: Add test cases that have trailing spaces before comment chars 2014-10-04 23:28:40 +08:00
core hashsig: Export as a sys header 2014-10-01 12:03:24 +02:00
date
describe Don't use cl_git_pass for POSIX functions 2014-10-10 15:17:27 -07:00
diff
fetchhead remote: allow overriding the refspecs for download and fetch 2014-09-30 15:42:32 +02:00
filter
graph
index tree-cache: correct the entry_count calculation 2014-10-22 21:25:08 +02:00
merge Merge pull request #2499 from csware/hard-reset-checkout-callbacks 2014-10-10 17:40:53 +02:00
network Merge pull request #2593 from libgit2/cmn/remote-delete-name 2014-10-10 12:21:28 -04:00
notes
object Factor 40 and 41 constants from source. 2014-09-16 13:07:04 +02:00
odb Fixed odb foreach test failure for big-endian 64-bit 2014-09-26 12:12:08 +02:00
online Merge pull request #2574 from csware/hostname-for-certificate_check_cb 2014-10-10 11:28:58 -04:00
pack Silence unused return value warning 2014-09-26 12:12:09 +02:00
path path: Fix git_path_walk_up to work with non-rooted paths 2014-09-17 15:00:12 +02:00
refs transaction: rename lock() to lock_ref() 2014-10-09 16:29:30 +02:00
repo Clean up some leaks in the test suite 2014-09-17 03:19:40 +02:00
reset
resources Introduce failing test for conflict filtering in index 2014-10-13 13:36:16 -04:00
revert
revwalk Add git_merge_bases_many. 2014-10-09 14:19:00 +02:00
stash p_mkdir != mkdir on win32 2014-10-03 19:30:48 -04:00
status
stress
structinit
submodule
threads global: free the error message when exiting a thread 2014-09-14 00:39:07 +02:00
trace
transport Clean up some leaks in the test suite 2014-09-17 03:19:40 +02:00
clar_libgit2.c
clar_libgit2.h
clar.c
clar.h
generate.py
main.c
README.md
valgrind-supp-mac.txt

Writing Clar tests for libgit2

For information on the Clar testing framework and a detailed introduction please visit:

https://github.com/vmg/clar

  • Write your modules and tests. Use good, meaningful names.

  • Make sure you actually build the tests by setting:

      cmake -DBUILD_CLAR=ON build/
    
  • Test:

      ./build/libgit2_clar
    
  • Make sure everything is fine.

  • Send your pull request. That's it.