Move Test::Asset* to Test::WebGUI::Asset*
This commit is contained in:
parent
2997471b5f
commit
85121c586c
49 changed files with 226 additions and 226 deletions
29
t/tests/Test/WebGUI/Asset/File.pm
Normal file
29
t/tests/Test/WebGUI/Asset/File.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::File;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::File/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData FileAsset/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/File/GalleryFile.pm
Normal file
29
t/tests/Test/WebGUI/Asset/File/GalleryFile.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::File::GalleryFile;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::File::GalleryFile/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData FileAsset GalleryFile/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/File/Image.pm
Normal file
29
t/tests/Test/WebGUI/Asset/File/Image.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::File::Image/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData FileAsset ImageAsset/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/File/ZipArchive.pm
Normal file
29
t/tests/Test/WebGUI/Asset/File/ZipArchive.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::File::ZipArchive;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::File::ZipArchive/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData FileAsset ZipArchiveAsset/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Redirect.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Redirect.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Redirect;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Redirect/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 9;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData redirect/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/RichEdit.pm
Normal file
33
t/tests/Test/WebGUI/Asset/RichEdit.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::RichEdit;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::RichEdit/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData RichEdit/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Shortcut.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Shortcut.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Shortcut;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Shortcut/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData Shortcut/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Sku.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Sku.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Sku;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Sku/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData sku/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Snippet.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Snippet.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Snippet;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Snippet/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData snippet/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Template.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Template.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Template;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Template/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData template/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Article.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Article.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Article;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Article/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Article/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Calendar.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Calendar.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Calendar;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Calendar/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Calendar/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Carousel.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Carousel.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Carousel;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Carousel/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Carousel/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/Collaboration
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/Collaboration
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::Asset::Wobject::HttpProxy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::AssetBase/;
|
||||
|
||||
use Test::More;
|
||||
use Test::Deep;
|
||||
use Test::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::HttpProxy/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject HttpProxy/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Collaboration.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Collaboration.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Collaboration;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Collaboration/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Collaboration assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/Dashboard.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/Dashboard.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::HttpProxy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::HttpProxy/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject HttpProxy/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/DataForm.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/DataForm.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::DataForm;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::DataForm/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject DataForm/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/DataTable.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/DataTable.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::DataTable;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::DataTable/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject DataTable/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/EventManagementSystem.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/EventManagementSystem.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::EventManagementSystem;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::EventManagementSystem/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject EventManagementSystem/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/Folder.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/Folder.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::Folder;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Folder/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Folder/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Gallery.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Gallery.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Gallery;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Gallery/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Gallery assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/GalleryAlbum.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/GalleryAlbum.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::GalleryAlbum;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::GalleryAlbum/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject GalleryAlbum assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/HttpProxy
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/HttpProxy
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::Asset::Wobject::HttpProxy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::AssetBase/;
|
||||
|
||||
use Test::More;
|
||||
use Test::Deep;
|
||||
use Test::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::HttpProxy/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject HttpProxy/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/HttpProxy.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/HttpProxy.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::HttpProxy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::HttpProxy/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject HttpProxy/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/InOutBoard.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/InOutBoard.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::InOutBoard;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::InOutBoard/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject InOutBoard/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Layout.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Layout.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Layout;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Layout/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Layout/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Map.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Map.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Map;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Map/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Map/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Matrix.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Matrix.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Matrix;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Matrix/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Matrix/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/MessageBoard.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/MessageBoard.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::MessageBoard;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::MessageBoard/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject MessageBoard/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/MultiSearch.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/MultiSearch.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::MultiSearch;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::MultiSearch/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject MultiSearch/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Navigation.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Navigation.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Navigation;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Navigation/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Navigation/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Poll.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Poll.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Poll;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Poll/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Poll/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/ProjectManager.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/ProjectManager.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::ProjectManager;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::ProjectManager/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject PM_wobject/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/SQLReport.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/SQLReport.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::SQLReport;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::SQLReport/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject SQLReport/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Search.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Search.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Search;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Search/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject search/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Shelf.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Shelf.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Shelf;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Shelf/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Shelf/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/StockData.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/StockData.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::StockData;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::StockData/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject StockData/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/StoryArchive.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/StoryArchive.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::StoryArchive;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::StoryArchive/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject StoryArchive assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/StoryTopic.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/StoryTopic.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::StoryTopic;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::StoryTopic/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject StoryTopic assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/Survey
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/Survey
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::Asset::Wobject::HttpProxy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::AssetBase/;
|
||||
|
||||
use Test::More;
|
||||
use Test::Deep;
|
||||
use Test::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::HttpProxy/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 5;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject HttpProxy/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Survey.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Survey.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Survey;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Survey/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Survey/];
|
||||
}
|
||||
|
||||
1;
|
||||
33
t/tests/Test/WebGUI/Asset/Wobject/SyndicatedContent.pm
Normal file
33
t/tests/Test/WebGUI/Asset/Wobject/SyndicatedContent.pm
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
package Test::WebGUI::Asset::Wobject::SyndicatedContent;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::SyndicatedContent/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 6;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject SyndicatedContent assetAspectRssFeed/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/Thingy.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/Thingy.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::Thingy;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::Thingy/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject Thingy/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/TimeTracking.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/TimeTracking.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::TimeTracking;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::TimeTracking/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject TT_wobject/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/UserList.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/UserList.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::UserList;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::UserList/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject UserList/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/WeatherData.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/WeatherData.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::WeatherData;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::WeatherData/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject WeatherData/];
|
||||
}
|
||||
|
||||
1;
|
||||
29
t/tests/Test/WebGUI/Asset/Wobject/WikiMaster.pm
Normal file
29
t/tests/Test/WebGUI/Asset/Wobject/WikiMaster.pm
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
package Test::WebGUI::Asset::Wobject::WikiMaster;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::WebGUI::AssetBase/;
|
||||
|
||||
use Test::WebGUI::More;
|
||||
use Test::WebGUI::Deep;
|
||||
use Test::WebGUI::Exception;
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset::Wobject::WikiMaster/;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData wobject WikiMaster assetAspectRssFeed assetAspectComments assetAspect_Subscribable/];
|
||||
}
|
||||
|
||||
1;
|
||||
330
t/tests/Test/WebGUI/AssetBase.pm
Normal file
330
t/tests/Test/WebGUI/AssetBase.pm
Normal file
|
|
@ -0,0 +1,330 @@
|
|||
package Test::WebGUI::AssetBase;
|
||||
#-------------------------------------------------------------------
|
||||
# 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 FindBin;
|
||||
use lib "$FindBin::Bin/lib";
|
||||
|
||||
use base qw/Test::Class/;
|
||||
use WebGUI::Test;
|
||||
|
||||
use Test::More;
|
||||
use Test::Deep;
|
||||
use Test::Exception;
|
||||
use WebGUI::Exception;
|
||||
|
||||
sub session {
|
||||
return shift->{_session};
|
||||
}
|
||||
|
||||
sub class {
|
||||
return qw/WebGUI::Asset/;
|
||||
}
|
||||
|
||||
sub assetUiLevel {
|
||||
return 1;
|
||||
}
|
||||
|
||||
sub list_of_tables {
|
||||
return [qw/assetData/];
|
||||
}
|
||||
|
||||
sub _00_init : Test(startup) {
|
||||
my $test = shift;
|
||||
my $session = WebGUI::Test->session;
|
||||
$test->{_session} = $session;
|
||||
note "Loading ". $test->class;
|
||||
eval { WebGUI::Asset->loadModule($test->class); };
|
||||
}
|
||||
|
||||
sub _constructor : Test(4) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
my $asset = $test->class->new({session => $session});
|
||||
|
||||
isa_ok $asset, $test->class;
|
||||
isa_ok $asset->session, 'WebGUI::Session';
|
||||
is $asset->session->getId, $session->getId, 'asset was assigned the correct session';
|
||||
|
||||
note "calling new with no assetId throws an exception";
|
||||
$asset = eval { WebGUI::Asset->new($session, ''); };
|
||||
my $e = Exception::Class->caught;
|
||||
isa_ok $e, 'WebGUI::Error';
|
||||
}
|
||||
|
||||
sub title : Test(6) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
my $asset = $test->class->new({session => $session});
|
||||
|
||||
note "title";
|
||||
can_ok $asset, 'title';
|
||||
is $asset->title, 'Untitled', 'title: default is untitled';
|
||||
|
||||
$asset->title('asset title');
|
||||
is $asset->title, 'asset title', '... set, get';
|
||||
$asset->title('');
|
||||
is $asset->title, 'Untitled', '... get default title when empty title set';
|
||||
$asset->title('<h1>Header</h1>text');
|
||||
is $asset->title, 'Headertext', '... HTML is filtered out';
|
||||
$asset->title('<h1></h1>');
|
||||
is $asset->title, 'Untitled', '... if HTML filters out all, returns default';
|
||||
|
||||
#is $asset->get('title'), $asset->title, '... get(title) works';
|
||||
|
||||
}
|
||||
|
||||
sub menuTitle : Test(8) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
my $asset = $test->class->new({session => $session});
|
||||
|
||||
note "menuTitle";
|
||||
|
||||
can_ok $asset, 'menuTitle';
|
||||
is $asset->menuTitle, 'Untitled', 'menuTitle: default is untitled';
|
||||
|
||||
$asset = $test->class->new({
|
||||
session => $session,
|
||||
title => 'asset title',
|
||||
});
|
||||
|
||||
is $asset->menuTitle, 'asset title', 'menuTitle: default is title';
|
||||
|
||||
$asset->menuTitle('asset menuTitle');
|
||||
is $asset->menuTitle, 'asset menuTitle', '... set and get';
|
||||
|
||||
$asset->menuTitle('');
|
||||
is $asset->menuTitle, 'asset title', '... set to default when trying to clear the title';
|
||||
|
||||
$asset->menuTitle('<h1>Header</h1>text');
|
||||
is $asset->menuTitle, 'Headertext', '... HTML is filtered out';
|
||||
$asset->menuTitle('<h1></h1>');
|
||||
is $asset->menuTitle, 'asset title', '... if HTML filters out all, returns default';
|
||||
|
||||
$asset = $test->class->new({
|
||||
session => $session,
|
||||
title => 'asset title',
|
||||
menuTitle => 'menuTitle asset',
|
||||
});
|
||||
is $asset->menuTitle, 'menuTitle asset', '... set via constructor';
|
||||
}
|
||||
|
||||
sub assetId : Test(4) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
my $asset = $test->class->new({session => $session});
|
||||
note "assetId, getId";
|
||||
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';
|
||||
|
||||
$asset = $test->class->new({ session => $session, assetId => '' });
|
||||
ok !$session->id->valid($asset->assetId), 'blank assetId in constructor is okay??';
|
||||
}
|
||||
|
||||
sub class_dispatch : Test(2) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "Class dispatch";
|
||||
my $asset = $test->class->new({session => $session});
|
||||
|
||||
my $asset = WebGUI::Asset->new({
|
||||
session => $session,
|
||||
title => 'testing snippet',
|
||||
className => 'WebGUI::Asset::Snippet',
|
||||
});
|
||||
|
||||
isa_ok $asset, 'WebGUI::Asset';
|
||||
is $asset->className, 'WebGUI::Asset', 'passing className is ignored';
|
||||
}
|
||||
|
||||
sub uiLevel : Test(1) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "uiLevel";
|
||||
my $asset = $test->class->new({session => $session});
|
||||
is $asset->uiLevel, $test->assetUiLevel, 'asset uiLevel check';
|
||||
}
|
||||
|
||||
sub write_update : Test(8) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "write, update";
|
||||
|
||||
my $testId = 'wg8TestAsset0000000001';
|
||||
my $revisionDate = time();
|
||||
$session->db->write("insert into asset (assetId) VALUES (?)", [$testId]);
|
||||
$session->db->write("insert into assetData (assetId, revisionDate) VALUES (?,?)", [$testId, $revisionDate]);
|
||||
|
||||
my $testAsset = WebGUI::Asset->new($session, $testId, $revisionDate);
|
||||
$testAsset->title('wg8 test title');
|
||||
$testAsset->lastModified(0);
|
||||
is $testAsset->assetSize, 0, 'assetSize is 0 by default';
|
||||
$testAsset->write();
|
||||
isnt $testAsset->lastModified, 0, 'lastModified updated on write';
|
||||
isnt $testAsset->assetSize, 0, 'assetSize updated on write';
|
||||
|
||||
my $testData = $session->db->quickHashRef('select * from assetData where assetId=? and revisionDate=?',[$testId, $revisionDate]);
|
||||
is $testData->{title}, 'wg8 test title', 'data written correctly to db';
|
||||
|
||||
$testAsset->update({
|
||||
isHidden => 1,
|
||||
encryptPage => 1,
|
||||
});
|
||||
|
||||
is $testAsset->isHidden, 1, 'isHidden set via update';
|
||||
is $testAsset->encryptPage, 1, 'encryptPage set via update';
|
||||
|
||||
$testData = $session->db->quickHashRef('select * from assetData where assetId=? and revisionDate=?',[$testId, $revisionDate]);
|
||||
is $testData->{isHidden}, 1, 'isHidden written correctly to db';
|
||||
is $testData->{encryptPage}, 1, 'encryptPage written correctly to db';
|
||||
|
||||
$session->db->write("delete from asset where assetId=?", [$testId]);
|
||||
$session->db->write("delete from assetData where assetId=?", [$testId]);
|
||||
}
|
||||
|
||||
sub keywords : Test(3) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "keywords";
|
||||
my $default = WebGUI::Asset->getDefault($session);
|
||||
my $asset = $default->addChild({
|
||||
className => $test->class,
|
||||
});
|
||||
addToCleanup($asset);
|
||||
can_ok $asset, 'keywords';
|
||||
$asset->keywords('chess set');
|
||||
is $asset->keywords, 'chess set', 'set and get of keywords via direct accessor';
|
||||
is $asset->get('keywords'), 'chess set', 'via get method';
|
||||
}
|
||||
|
||||
sub get_tables : Test(1) {
|
||||
my $test = shift;
|
||||
note "get_tables";
|
||||
my @tables = $test->class->meta->get_tables;
|
||||
cmp_bag(
|
||||
\@tables,
|
||||
$test->list_of_tables,
|
||||
'Set of tables for properties is correct'
|
||||
);
|
||||
}
|
||||
|
||||
sub getParent : Test(2) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "getParent";
|
||||
my $testId1 = 'wg8TestAsset0000000001';
|
||||
my $testId2 = 'wg8TestAsset0000000002';
|
||||
my $now = time();
|
||||
my $baseLineage = $session->db->quickScalar('select lineage from asset where assetId=?',['PBasset000000000000002']);
|
||||
my $testLineage = $baseLineage. '909090';
|
||||
$session->db->write("insert into asset (assetId, className, lineage) VALUES (?,?,?)", [$testId1, 'WebGUI::Asset', $testLineage]);
|
||||
$session->db->write("insert into assetData (assetId, revisionDate, status) VALUES (?,?,?)", [$testId1, $now, 'approved']);
|
||||
my $testLineage2 = $testLineage . '000001';
|
||||
$session->db->write("insert into asset (assetId, className, parentId, lineage) VALUES (?,?,?,?)", [$testId2, 'WebGUI::Asset', $testId1, $testLineage2]);
|
||||
$session->db->write("insert into assetData (assetId, revisionDate) VALUES (?,?)", [$testId2, $now]);
|
||||
|
||||
my $testAsset = WebGUI::Asset->new($session, $testId2, $now);
|
||||
is $testAsset->parentId, $testId1, 'parentId assigned correctly on db fetch in new';
|
||||
my $testParent = $testAsset->getParent();
|
||||
isa_ok $testParent, 'WebGUI::Asset';
|
||||
|
||||
$session->db->write("delete from asset where assetId like 'wg8TestAsset00000%'");
|
||||
$session->db->write("delete from assetData where assetId like 'wg8TestAsset00000%'");
|
||||
}
|
||||
|
||||
sub addRevision : Test(6) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "addRevision";
|
||||
my $testId1 = 'wg8TestAsset0000000001';
|
||||
my $testId2 = 'wg8TestAsset0000000002';
|
||||
my $now = time();
|
||||
my $revisionDate = $now - 50;
|
||||
my $baseLineage = $session->db->quickScalar('select lineage from asset where assetId=?',['PBasset000000000000002']);
|
||||
my $testLineage = $baseLineage. '909090';
|
||||
$session->db->write("insert into asset (assetId, className, lineage) VALUES (?,?,?)", [$testId1, 'WebGUI::Asset', $testLineage]);
|
||||
$session->db->write("insert into assetData (assetId, revisionDate, status) VALUES (?,?,?)", [$testId1, $revisionDate, 'approved']);
|
||||
my $testLineage2 = $testLineage . '000001';
|
||||
$session->db->write("insert into asset (assetId, className, parentId, lineage) VALUES (?,?,?,?)", [$testId2, 'WebGUI::Asset', $testId1, $testLineage2]);
|
||||
$session->db->write("insert into assetData (assetId, revisionDate) VALUES (?,?)", [$testId2, $revisionDate]);
|
||||
|
||||
my $testAsset = WebGUI::Asset->new($session, $testId2, $revisionDate);
|
||||
$testAsset->title('test title 43');
|
||||
$testAsset->write();
|
||||
my $tag = WebGUI::VersionTag->getWorking($session);
|
||||
my $revAsset = $testAsset->addRevision({}, $now);
|
||||
isa_ok $revAsset, 'WebGUI::Asset';
|
||||
is $revAsset->revisionDate, $now, 'revisionDate set correctly on new revision';
|
||||
is $revAsset->title, 'test title 43', 'data fetch from database correct';
|
||||
is $revAsset->revisedBy, $session->user->userId, 'revisedBy is current session user';
|
||||
is $revAsset->tagId, $tag->getId, 'tagId is current working tagId';
|
||||
my $count = $session->db->quickScalar('SELECT COUNT(*) from assetData where assetId=?',[$testId2]);
|
||||
is $count, 2, 'two records in the database';
|
||||
addToCleanup($tag);
|
||||
|
||||
$session->db->write("delete from asset where assetId like 'wg8TestAsset00000%'");
|
||||
$session->db->write("delete from assetData where assetId like 'wg8TestAsset00000%'");
|
||||
}
|
||||
|
||||
sub newByPropertyHashRef : Test(2) {
|
||||
my $test = shift;
|
||||
my $session = $test->session;
|
||||
note "newByPropertyHashRef";
|
||||
my $asset;
|
||||
$asset = WebGUI::Asset->newByPropertyHashRef($session, {className => $test->class, title => 'The Shawshank Snippet'});
|
||||
isa_ok $asset, $test->class;
|
||||
is $asset->title, 'The Shawshank Snippet', 'title is assigned from the property hash';
|
||||
}
|
||||
|
||||
|
||||
1;
|
||||
|
||||
__END__
|
||||
|
||||
{
|
||||
note "getClassById";
|
||||
my $class;
|
||||
$class = WebGUI::Asset->getClassById($session, 'PBasset000000000000001');
|
||||
is $class, 'WebGUI::Asset', 'getClassById: retrieve a class';
|
||||
$class = WebGUI::Asset->getClassById($session, 'PBasset000000000000001');
|
||||
is $class, 'WebGUI::Asset', '... cache check';
|
||||
$class = WebGUI::Asset->getClassById($session, 'PBasset000000000000002');
|
||||
is $class, 'WebGUI::Asset::Wobject::Folder', '... retrieve another class';
|
||||
}
|
||||
|
||||
{
|
||||
note "new, fetching from db";
|
||||
my $asset;
|
||||
$asset = WebGUI::Asset->new($session, 'PBasset000000000000001');
|
||||
isa_ok $asset, 'WebGUI::Asset';
|
||||
is $asset->title, 'Root', 'got the right asset';
|
||||
}
|
||||
|
||||
{
|
||||
note "getDefault";
|
||||
my $asset = WebGUI::Asset->getDefault($session);
|
||||
isa_ok $asset, 'WebGUI::Asset::Wobject::Layout';
|
||||
}
|
||||
|
||||
{
|
||||
note "get gets WebGUI::Definition properties, and standard attributes";
|
||||
my $asset = WebGUI::Asset->new({session => $session, parentId => 'I have a parent'});
|
||||
is $asset->get('className'), 'WebGUI::Asset', 'get(property) works on className';
|
||||
is $asset->get('assetId'), $asset->assetId, '... works on assetId';
|
||||
is $asset->get('parentId'), 'I have a parent', '... works on parentId';
|
||||
my $properties = $asset->get();
|
||||
is $properties->{className}, 'WebGUI::Asset', 'get() works on className';
|
||||
is $properties->{assetId}, $asset->assetId, '... works on assetId';
|
||||
is $properties->{parentId}, 'I have a parent', '... works on parentId';
|
||||
}
|
||||
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue