libgit2/tests
Carlos Martín Nieto ccb85c8fa1 ssh: make sure to ask for a username and use the same one
In order to know which authentication methods are supported/allowed by
the ssh server, we need to send a NONE auth request, which needs a
username associated with it.

Most ssh server implementations do not allow switching the username
between authentication attempts, which means we cannot use a dummy
username and then switch. There are two ways around this.

The first is to use a different connection, which an earlier commit
implements, but this increases how long it takes to get set up, and
without knowing the right username, we cannot guarantee that the
list we get in response is the right one.

The second is what's implemented here: if there is no username specified
in the url, ask for it first. We can then ask for the list of auth
methods and use the user's credentials in the same connection.
2014-06-26 22:58:39 +02:00
..
attr Some further sandboxing cleanups to tests 2014-05-02 09:21:33 -07:00
blame Clar: skip tests 2014-04-02 18:50:47 +02:00
buf Rename tests-clar to tests 2013-11-14 14:05:52 -08:00
checkout git_checkout_opts -> git_checkout_options 2014-03-06 09:44:51 -08:00
cherrypick Added cherry pick tests 2014-04-14 16:16:22 +02:00
clar Clar: skip tests 2014-04-02 18:50:47 +02:00
clone clone: more explicit local tests 2014-05-29 10:06:48 +02:00
commit commit: safer commit creation with reference update 2014-04-30 00:41:37 +02:00
config Merge pull request #2313 from libgit2/cmn/remote-delete 2014-05-16 11:56:37 +02:00
core fileops: allow linking files when copying directory structures 2014-05-28 15:40:22 +02:00
date Added RFC2822 date format test cases 2014-04-11 21:55:36 +02:00
diff Fix compile error on Visual Studio 2014-05-27 23:36:07 +09:00
fetchhead fetchhead: deal with quotes in branch names 2014-04-24 14:08:29 +02:00
filter Ignore core.safecrlf=warn until we have a warn infrastructure 2014-05-30 11:30:53 -05:00
graph Added a no path test for git_graph_descendant_of 2014-04-08 16:32:06 +02:00
index Plug a leak in the tests 2014-06-03 16:18:08 +02:00
merge Modify GIT_MERGE_CONFIG -> GIT_MERGE_PREFERENCE 2014-05-27 20:58:20 -05:00
network remote: don't free the remote on delete 2014-06-06 22:55:34 +02:00
notes note: rename the id getter to git_note_id() 2014-01-24 11:18:51 +01:00
object Win32: Fix object::cache::threadmania test on x64 2014-06-07 12:51:48 -04:00
odb Fix a leak in the tests 2014-05-20 08:29:51 +02:00
online ssh: make sure to ask for a username and use the same one 2014-06-26 22:58:39 +02:00
pack Fix a bug in the pack::packbuilder suite 2014-05-17 16:58:09 -04:00
refs refs: failing test for concurrent ref access 2014-06-02 16:46:47 +02:00
repo Fix compile error on Visual Studio 2014-05-27 23:36:07 +09:00
reset Reset tests: Use sandboxed index 2014-04-25 15:49:58 +02:00
resources Merge pull request #2261 from jacquesg/format-patch 2014-04-16 19:09:35 +02:00
revert Capture conflict information in MERGE_MSG for revert and merge 2014-04-14 16:16:22 +02:00
revwalk No need to find merge base. 2014-03-31 15:15:32 -07:00
stash Make checkout match diff for untracked/ignored dir 2014-04-22 21:51:54 -07:00
status Improve checks for ignore containment 2014-05-06 12:41:26 -07:00
stress Rename tests-clar to tests 2013-11-14 14:05:52 -08:00
structinit Fix remaining init_options inconsistencies 2014-05-02 09:21:33 -07:00
submodule Merge pull request #2407 from libgit2/cmn/remote-rename-more 2014-06-08 16:44:32 +02:00
threads Win32: Fix object::cache::threadmania test on x64 2014-06-07 12:51:48 -04:00
trace Remove trace / add git_diff_perfdata struct + api 2014-05-02 09:21:33 -07:00
clar_libgit2.c Better search path sandboxing 2014-05-15 10:56:28 -07:00
clar_libgit2.h Better search path sandboxing 2014-05-15 10:56:28 -07:00
clar.c Clar: skip tests 2014-04-02 18:50:47 +02:00
clar.h Clar: skip tests 2014-04-02 18:50:47 +02:00
generate.py Rename tests-clar to tests 2013-11-14 14:05:52 -08:00
main.c Better search path sandboxing 2014-05-15 10:56:28 -07:00
README.md Rename tests-clar to tests 2013-11-14 14:05:52 -08:00
valgrind-supp-mac.txt Test cancel from indexer progress callback 2013-12-11 15:02:20 -08:00

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.