Import node can't be used to test getBackToSiteURL since that forces the user back to the default asset.
This commit is contained in:
parent
78a12c18e9
commit
25b981baec
1 changed files with 6 additions and 3 deletions
|
|
@ -398,11 +398,14 @@ TODO: {
|
||||||
ok(0, 'test a child of the media folder');
|
ok(0, 'test a child of the media folder');
|
||||||
}
|
}
|
||||||
|
|
||||||
my $parentAsset = WebGUI::Test->asset;
|
my $versionTag = WebGUI::VersionTag->getWorking($session);
|
||||||
|
WebGUI::Test->addToCleanup($versionTag);
|
||||||
|
my $parentAsset = WebGUI::Asset->getRoot($session);
|
||||||
my $statefulAsset = $parentAsset->addChild({ className => 'WebGUI::Asset::Snippet' });
|
my $statefulAsset = $parentAsset->addChild({ className => 'WebGUI::Asset::Snippet' });
|
||||||
$session->asset( $statefulAsset );
|
$versionTag->commit;
|
||||||
|
$statefulAsset = $statefulAsset->cloneFromDb;
|
||||||
|
$session->asset($statefulAsset);
|
||||||
|
|
||||||
$statefulAsset->state('published');
|
|
||||||
is(
|
is(
|
||||||
$session->url->getBackToSiteURL,
|
$session->url->getBackToSiteURL,
|
||||||
$parentAsset->getUrl,
|
$parentAsset->getUrl,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue