add test for macro processing of genAddHeadTags and for handling of invalid template Id in process for Session::Style
This commit is contained in:
parent
a713e90d9b
commit
30a47092be
1 changed files with 15 additions and 5 deletions
|
|
@ -16,7 +16,7 @@ use HTML::TokeParser;
|
|||
use WebGUI::Test;
|
||||
use WebGUI::Session;
|
||||
|
||||
use Test::More tests => 34; # increment this value for each test you create
|
||||
use Test::More tests => 35; # increment this value for each test you create
|
||||
use Test::Deep;
|
||||
|
||||
my $session = WebGUI::Test->session;
|
||||
|
|
@ -141,10 +141,20 @@ TODO: {
|
|||
#
|
||||
####################################################
|
||||
|
||||
TODO: {
|
||||
local $TODO = "more generateAdditionalHeadTags tests";
|
||||
ok(0, 'check for Macro processing in generateAdditionalHeadTags');
|
||||
}
|
||||
$session->user({userId => 1});
|
||||
$style->setRawHeadTags("^#;");
|
||||
my $macroOutput = $style->generateAdditionalHeadTags();
|
||||
is($macroOutput, 1, 'generateAdditionalHeadTags: process a macro');
|
||||
|
||||
####################################################
|
||||
#
|
||||
# process
|
||||
#
|
||||
####################################################
|
||||
|
||||
is($style->process('body.content', 'notATemplateId'),
|
||||
"WebGUI was unable to instantiate your style template.body.content",
|
||||
'process: invalid templateId returns error message to client');
|
||||
|
||||
sub simpleLinkParser {
|
||||
my ($tokenName, $text) = @_;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue