Fixed bug #10982 where survey admin menu options appear twice. Caused by the Survey Asset directly calling its parent getAdminConsole method instead of instantiating a session instance of the method.
This commit is contained in:
parent
5ee64a57d3
commit
082b04b967
3 changed files with 45 additions and 2 deletions
|
|
@ -18,7 +18,7 @@ my $session = WebGUI::Test->session;
|
|||
|
||||
#----------------------------------------------------------------------------
|
||||
# Tests
|
||||
my $tests = 45;
|
||||
my $tests = 46;
|
||||
plan tests => $tests + 1;
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
|
@ -272,3 +272,45 @@ like($storage->getFileContentsAsScalar($filename), qr{
|
|||
|
||||
}
|
||||
|
||||
my $adminConsole = $survey->getAdminConsole();
|
||||
cmp_deeply(
|
||||
$adminConsole->{_submenuItem},
|
||||
[
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=edit',
|
||||
'label' => 'Edit'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=editSurvey',
|
||||
'label' => 'Edit Survey'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=takeSurvey',
|
||||
'label' => 'Take Survey'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=graph',
|
||||
'label' => 'Visualize'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=editTestSuite',
|
||||
'label' => 'Test Suite'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=runTests',
|
||||
'label' => 'Run All Tests'
|
||||
},
|
||||
{
|
||||
'extras' => undef,
|
||||
'url' => '/home?func=runTests;format=tap',
|
||||
'label' => 'Run All Tests (TAP)'
|
||||
}
|
||||
],
|
||||
"Admin console submenu",
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue