19 |
|
|
20 |
# Try testing a create |
# Try testing a create |
21 |
my $o = SVNBrowser::Model::Action->new(current_user => $system_user); |
my $o = SVNBrowser::Model::Action->new(current_user => $system_user); |
22 |
my ($id) = $o->create(); |
my ($id) = $o->create( |
23 |
|
revision => 1, |
24 |
|
type => 'A', |
25 |
|
branch => '/trunk', |
26 |
|
rel_path => '/foo', |
27 |
|
); |
28 |
ok($id, "Action create returned success"); |
ok($id, "Action create returned success"); |
29 |
ok($o->id, "New Action has valid id set"); |
ok($o->id, "New Action has valid id set"); |
30 |
is($o->id, $id, "Create returned the right id"); |
is($o->id, $id, "Create returned the right id"); |
31 |
|
|
32 |
# And another |
# And another |
33 |
$o->create(); |
$o->create( |
34 |
|
revision => 2, |
35 |
|
type => 'M', |
36 |
|
branch => '/trunk', |
37 |
|
rel_path => '/foo', |
38 |
|
); |
39 |
ok($o->id, "Action create returned another value"); |
ok($o->id, "Action create returned another value"); |
40 |
isnt($o->id, $id, "And it is different from the previous one"); |
isnt($o->id, $id, "And it is different from the previous one"); |
41 |
|
|