diff --git a/t/Asset.t b/t/Asset.t index 256b4bab1..a1a11f38d 100644 --- a/t/Asset.t +++ b/t/Asset.t @@ -20,7 +20,7 @@ use Test::More; use Test::Deep; use Test::Exception; -plan tests => 29; +plan tests => 31; my $session = WebGUI::Test->session; @@ -48,10 +48,16 @@ my $session = WebGUI::Test->session; is $asset->get('title'), $asset->title, '... get(title) works'; is $asset->menuTitle, 'Untitled', 'menuTitle: default is untitled'; +} +{ + note "assetId, getId"; + my $asset = WebGUI::Asset->new({session => $session, }); can_ok $asset, qw/assetId getId/; ok $session->id->valid( $asset->assetId), 'assetId generated by default is valid'; is $asset->assetId, $asset->getId, '... getId is an alias for assetId'; + + my $asset2 = WebGUI::Asset->new({ session => $session, assetId => '' }); } { @@ -145,3 +151,8 @@ my $session = WebGUI::Test->session; note "uiLevel"; is +WebGUI::Asset->meta->uiLevel, 1, 'uiLevel: default for assets is 1'; } + +{ + note "write"; + is +WebGUI::Asset->meta->uiLevel, 1, 'uiLevel: default for assets is 1'; +}