This test is failing in the smoke-tests, but manual runs by two different
people on different OS'es are passing. I've added some diagnostic tests to help us figure out what's going on.
This commit is contained in:
parent
e03d761eca
commit
d6a62df50c
1 changed files with 10 additions and 2 deletions
|
|
@ -16,7 +16,7 @@ use lib "$FindBin::Bin/../../lib";
|
|||
|
||||
use WebGUI::Test;
|
||||
use WebGUI::Session;
|
||||
use Test::More tests => 17; # increment this value for each test you create
|
||||
use Test::More tests => 19; # increment this value for each test you create
|
||||
use WebGUI::Asset::Wobject::Article;
|
||||
|
||||
my $session = WebGUI::Test->session;
|
||||
|
|
@ -68,8 +68,14 @@ my $filename = "page_title.jpg";
|
|||
|
||||
# Use some test collateral to create a storage location and assign it to our article
|
||||
my $storage = WebGUI::Storage::Image->create($session);
|
||||
$storage->addFileFromFilesystem("../../supporting_collateral/".$filename);
|
||||
my $storedFilename = $storage->addFileFromFilesystem("../../supporting_collateral/".$filename);
|
||||
my $filenameOK = is ($storedFilename, $filename, 'storage created correctly');
|
||||
$article->update({storageId=>$storage->getId});
|
||||
my $storageOK = is($article->get('storageId'), $storage->getId, 'correct storage id stored');
|
||||
|
||||
SKIP: {
|
||||
|
||||
skip 'storage test setup problem', 3 unless $filenameOK and $storageOK;
|
||||
|
||||
my $duplicateArticle = $article->duplicate();
|
||||
isa_ok($duplicateArticle, 'WebGUI::Asset::Wobject::Article');
|
||||
|
|
@ -92,6 +98,8 @@ $duplicateFilename = $duplicateStorage->getFiles->[0];
|
|||
|
||||
is ($duplicateFilename, undef, 'purge method deletes collateral');
|
||||
|
||||
}
|
||||
|
||||
TODO: {
|
||||
local $TODO = "Tests to make later";
|
||||
ok(0, 'Test exportAssetData method');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue