gitolite/t
Sitaram Chamarty a430cc57c7 separating "push" from "create"
This is what I *should* have done back then; thanks to Jeff Mitchell for
pointing out a problem with the old method.

The old one is *definitely* a kludge.  <shamefaced grin>
2010-06-18 21:34:43 +05:30
..
keys finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
out finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
basic.conf finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
cleanout-gitolite finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
install-gitolite finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
README.mkd finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
rollback finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
rollback.server finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t-fedora-big-config finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t00-initial log message changes (warning: minor backward compat breakage) 2010-06-16 17:22:37 +05:30
t01-repo-groups finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t02-user-groups finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t03-branch-permissions finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t03a-branch-permissions finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t04-wild finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t04a-wild-all finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t04a-wild-students finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t05-delegation finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t05a-delegation finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t09-oldtests finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t09a-oldtests finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t50-sequence-test finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t51-personal-branches finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
t52-deny-create-ref separating "push" from "create" 2010-06-18 21:34:43 +05:30
t53-check-info-expand-output add a new test to make sure "info" and "expand" show the right output 2010-06-12 13:24:59 +05:30
test-driver.sh finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30
update-gitolite finally, open up my secret test scripts... 2010-06-12 13:24:55 +05:30

notes on the testing setup

In this document:

terminology

#define PW "patches welcome!"
#define TODO PW

notes and background

  • all testing is done on one machine, using 2 userids

  • test driver exits on the first failed test; no fancy counting here. (PW).

  • installs are done using "gl-easy-install". As such, this test suite is mainly meant for testing the core (access control) functionality, and will not help you test the install/upgrade parts themselves. Those are a lot more difficult to test in an automated fashion, but luckily they also change infrequently and can easily be tested manually when they do. Errors in those are much more visible too. (PW).

  • the test driver has evolved as new scripts were added; you will see that older scripts are a little less sophisticated.

quick instructions for running the test suite

  • create two brand new user IDs: tester and gitolite-test

    • these are hard-coded, sorry. (PW)
    • give them some passwords
    • allow ssh into gitolite-test in /etc/ssh/sshd_config; preferably use a line like AllowUsers gitolite-test@127.0.0.1 so that no one can ssh in from outside
  • prepare/push a bare clone of gitolite itself on /tmp so that the "tester" userid can grab it painlessly

    cd your-gitolite-working-repo
    git clone --bare $PWD /tmp/gitolite                 # first time
    git push -f --all /tmp/gitolite                     # subsequent times
    
  • "su" to "tester" and clone/fetch the gitolite source:

    cd $HOME; git clone /tmp/gitolite                   # first time
    cd gitolite; git fetch origin                       # subsequent times
    
  • checkout and "install" the branch you want to test (install from "tester" userid to "gitolite-test" userid). Example, if you want to test "pu" branch:

    git checkout -t origin/pu                           # if needed
    git checkout -f pu; git reset --hard origin/pu      # subsequent times
    cd t        # THIS IS IMPORTANT (patches welcome, or will be fixed eventually!)
    ./install-gitolite
    
  • run all or some of the tests

    ./test-driver.sh
    # or
    ./test-driver.sh t51
    

instructions for adding new tests

(TODO)