webgui/t/tests/Test/WebGUI/Asset/File/Image.pm
2010-07-15 11:55:25 -05:00

39 lines
1.2 KiB
Perl

package Test::WebGUI::Asset::File::Image;
#-------------------------------------------------------------------
# WebGUI is Copyright 2001-2009 Plain Black Corporation.
#-------------------------------------------------------------------
# Please read the legal notices (docs/legal.txt) and the license
# (docs/license.txt) that came with this distribution before using
# this software.
#-------------------------------------------------------------------
# http://www.plainblack.com info@plainblack.com
#-------------------------------------------------------------------
use base qw/Test::WebGUI::Asset/;
use Test::More;
use Test::Deep;
use Test::Exception;
sub list_of_tables {
return [qw/assetData FileAsset ImageAsset/];
}
sub t_11_getEditForm : Tests( 2 ) {
my $test = shift;
$test->SUPER::getEditForm( @_ );
my $session = $test->session;
my ( $tag, $asset, @parents ) = $test->getAnchoredAsset();
# Test extra fields
my $f = $asset->getEditForm;
isa_ok( $f->getTab("properties")->getField("thumbnail"), "WebGUI::Form::ReadOnly" );
isa_ok( $f->getTab("properties")->getField("imageSize"), "WebGUI::Form::ReadOnly" );
# TODO: Test overrides for extra fields
}
1;