adding test for id returned from calling find with a non-existant group name
This commit is contained in:
parent
cfea8f573a
commit
0be1193574
1 changed files with 6 additions and 1 deletions
|
|
@ -75,7 +75,7 @@ my @ipTests = (
|
|||
);
|
||||
|
||||
|
||||
plan tests => (119 + scalar(@scratchTests) + scalar(@ipTests)); # increment this value for each test you create
|
||||
plan tests => (121 + scalar(@scratchTests) + scalar(@ipTests)); # increment this value for each test you create
|
||||
|
||||
my $session = WebGUI::Test->session;
|
||||
my $testCache = WebGUI::Cache->new($session, 'myTestKey');
|
||||
|
|
@ -130,6 +130,11 @@ SKIP: {
|
|||
}
|
||||
undef $g2;
|
||||
|
||||
$g2 = WebGUI::Group->find($session, 'Non existant group name');
|
||||
is(ref $g2, 'WebGUI::Group', 'find with non-existant group name returns a group');
|
||||
is($g2->getId, undef, 'find with non-existant group name returns a group with undefined ID');
|
||||
|
||||
|
||||
delete $g->{_group};
|
||||
ok( !exists $g->{_group}, 'deleted group property hash');
|
||||
is( $g->name, $gname, 'group name restored after ->get through ->name');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue