mirror of
https://git.proxmox.com/git/libgit2
synced 2025-10-25 15:19:41 +00:00
This makes it easy to take a buffer containing a path with relative references (i.e. .. or . path segments) and resolve all of those into a clean path. This can be applied to URLs as well as file paths which can be useful. As part of this, I made the drive-letter detection apply on all platforms, not just windows. If you give a path that looks like "c:/..." on any platform, it seems like we might as well detect that as a rooted path. I suppose if you create a directory named "x:" on another platform and want to use that as the beginning of a relative path under the root directory of your repo, this could cause a problem, but then it seems like you're asking for trouble. |
||
|---|---|---|
| .. | ||
| attr | ||
| buf | ||
| commit | ||
| config | ||
| core | ||
| date | ||
| diff | ||
| index | ||
| network | ||
| notes | ||
| object | ||
| odb | ||
| refs | ||
| repo | ||
| reset | ||
| resources | ||
| revwalk | ||
| status | ||
| threads | ||
| clar | ||
| clar_helpers.c | ||
| clar_libgit2.h | ||
| README.md | ||
Writing Clar tests for libgit2
For information on the Clar testing framework and a detailed introduction please visit:
https://github.com/tanoku/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.