summaryrefslogtreecommitdiffstats
path: root/t/reset
blob: 502de2bce2004d2e6aaffba6973ffa2f8a0afd10 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/usr/bin/perl
use strict;
use warnings;

BEGIN {
    unlink "$ENV{HOME}/.ssh/authorized_keys";
}

# this is hardcoded; change it if needed
use lib "src/lib";
use Gitolite::Test;

use Cwd;
my $workdir = getcwd();

confreset;confadd '
repo foo/..*
    C   =   u1 u2 u3
    RW+ =   CREATOR
    RW  =   WRITERS
    R   =   READERS
';

try "ADMIN_PUSH set1; !/FATAL/" or die text();

try "
    mkdir -p keydir
    cp \$HOME/.ssh/u*.pub keydir
    cp \$HOME/.ssh/admin.pub keydir
    git add keydir
    git commit -m 6k
    glt push admin origin
";