Update version for JavaScript::Packed to handle some gnarly JS. Fixes bug #11034.
This commit is contained in:
parent
d04d457d44
commit
ea53dcc037
4 changed files with 1138 additions and 2 deletions
|
|
@ -12,6 +12,7 @@
|
|||
- fixed #11355: Duplicate template error
|
||||
- fixed #11347: copy forum
|
||||
- fixed #11359: USPS International shipping does not work on United Kingdom
|
||||
- fixed #11034: Upgrade errors -- 7.6.35 to 7.7.17
|
||||
|
||||
7.8.9
|
||||
- fixed #11235: wiki search
|
||||
|
|
|
|||
|
|
@ -125,7 +125,7 @@ checkModule("Class::C3", "0.21" );
|
|||
checkModule("Params::Validate", "0.91" );
|
||||
checkModule("Clone", "0.31" );
|
||||
checkModule('HTML::Packer', "0.4" );
|
||||
checkModule('JavaScript::Packer', '0.02' );
|
||||
checkModule('JavaScript::Packer', '0.04' );
|
||||
checkModule('CSS::Packer', '0.2' );
|
||||
checkModule('Business::Tax::VAT::Validation', '0.20' );
|
||||
checkModule('Crypt::SSLeay', '0.57' );
|
||||
|
|
|
|||
|
|
@ -16,7 +16,8 @@ use lib "$FindBin::Bin/../lib";
|
|||
|
||||
use WebGUI::Test;
|
||||
use WebGUI::Session;
|
||||
use Test::More tests => 18; # increment this value for each test you create
|
||||
use Test::More tests => 21; # increment this value for each test you create
|
||||
use Test::Exception;
|
||||
use WebGUI::Asset::Snippet;
|
||||
|
||||
my $session = WebGUI::Test->session;
|
||||
|
|
@ -101,6 +102,28 @@ is $snippet->view, 'Cache test: 1', 'validate snippet content and set cache';
|
|||
$session->user({userId => 3});
|
||||
is $snippet->view(1), 'Cache test: 3', 'receive uncached content since view was passed the webMethod flag';
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
#Check packing
|
||||
|
||||
my $snippet2 = $node->addChild({className => 'WebGUI::Asset::Snippet'});
|
||||
my $tag2 = WebGUI::VersionTag->getWorking($session);
|
||||
$snippet2->update({mimeType => 'text/javascript'});
|
||||
$tag2->commit;
|
||||
addToCleanup($tag2);
|
||||
|
||||
open my $JSFILE, WebGUI::Test->getTestCollateralPath('jquery.js')
|
||||
or die "Unable to open jquery test collateral file: $!";
|
||||
my $jquery;
|
||||
{
|
||||
undef $/;
|
||||
$jquery = <$JSFILE>;
|
||||
};
|
||||
close $JSFILE;
|
||||
|
||||
is $snippet2->get('snippetPacked'), undef, 'no packed content';
|
||||
lives_ok { $snippet2->update({snippet => $jquery}); } 'did not die during packing jquery';
|
||||
ok $snippet2->get('snippetPacked'), 'snippet content was packed';
|
||||
|
||||
TODO: {
|
||||
local $TODO = "Tests to make later";
|
||||
ok(0, 'Test indexContent method');
|
||||
|
|
|
|||
1112
t/supporting_collateral/jquery.js
vendored
Normal file
1112
t/supporting_collateral/jquery.js
vendored
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue