Adjust test cases to sprited icons
This commit is contained in:
parent
ba395f545e
commit
e490bdd262
@ -30,7 +30,7 @@ class PMA_getIcon_test extends PHPUnit_Framework_TestCase{
|
||||
$GLOBALS['pmaThemeImage'] = 'theme/';
|
||||
|
||||
$this->assertEquals('<span class="nowrap"><img src="'.$GLOBALS['pmaThemeImage']
|
||||
. 'b_comment.png" title="" alt="" class="icon" width="16" height="16" /></span>',
|
||||
. 'dot.gif" title="" alt="" class="icon ic_b_comment" /></span>',
|
||||
PMA_getIcon('b_comment.png') );
|
||||
}
|
||||
|
||||
@ -41,8 +41,8 @@ class PMA_getIcon_test extends PHPUnit_Framework_TestCase{
|
||||
$alternate_text = 'alt_str';
|
||||
|
||||
$this->assertEquals('<span class="nowrap"><img src="'.$GLOBALS['pmaThemeImage']
|
||||
.'b_comment.png" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon" width="16" height="16" /></span>',
|
||||
.'dot.gif" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon ic_b_comment" /></span>',
|
||||
PMA_getIcon('b_comment.png',$alternate_text) );
|
||||
}
|
||||
|
||||
@ -53,8 +53,8 @@ class PMA_getIcon_test extends PHPUnit_Framework_TestCase{
|
||||
$alternate_text = 'alt_str';
|
||||
|
||||
$this->assertEquals('<span class="nowrap"><img src="'.$GLOBALS['pmaThemeImage']
|
||||
.'b_comment.png" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon" width="16" height="16" /></span>',
|
||||
.'dot.gif" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon ic_b_comment" /></span>',
|
||||
PMA_getIcon('b_comment.png',$alternate_text, true) );
|
||||
|
||||
}
|
||||
@ -66,9 +66,9 @@ class PMA_getIcon_test extends PHPUnit_Framework_TestCase{
|
||||
$alternate_text = 'alt_str';
|
||||
|
||||
$this->assertEquals('<span class="nowrap"><img src="'.$GLOBALS['pmaThemeImage']
|
||||
.'b_comment.png" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon" width="16" height="16" /> ' . $alternate_text . '</span>',
|
||||
.'dot.gif" title="' . $alternate_text . '" alt="' . $alternate_text
|
||||
. '" class="icon ic_b_comment" /> ' . $alternate_text . '</span>',
|
||||
PMA_getIcon('b_comment.png',$alternate_text, true, true) );
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -25,7 +25,7 @@ class PMA_showDocu_test extends PHPUnit_Framework_TestCase
|
||||
$GLOBALS['cfg']['ReplaceHelpImg'] = true;
|
||||
|
||||
$anchor = "relation";
|
||||
$expected = '<a href="Documentation.html#' . $anchor . '" target="documentation"><img class="icon" src="' . $GLOBALS['pmaThemeImage'] . 'b_help.png" width="11" height="11" alt="' . __('Documentation') . '" title="' . __('Documentation') . '" /></a>';
|
||||
$expected = '<a href="Documentation.html#' . $anchor . '" target="documentation"><img class="icon ic_b_help_s" src="' . $GLOBALS['pmaThemeImage'] . 'dot.gif" alt="' . __('Documentation') . '" title="' . __('Documentation') . '" /></a>';
|
||||
|
||||
$this->assertEquals($expected, PMA_showDocu($anchor));
|
||||
|
||||
|
||||
@ -21,8 +21,8 @@ class PMA_showPHPDocu_test extends PHPUnit_Framework_TestCase
|
||||
|
||||
$target = "docu";
|
||||
$lang = _pgettext('PHP documentation language', 'en');
|
||||
$expected = '<a href="http://php.net/manual/' . $lang . '/' . $target . '" target="documentation"><img class="icon" src="'
|
||||
. $GLOBALS['pmaThemeImage'] . 'b_help.png" width="11" height="11" alt="' . __('Documentation') . '" title="' . __('Documentation') . '" /></a>';
|
||||
$expected = '<a href="http://php.net/manual/' . $lang . '/' . $target . '" target="documentation"><img class="icon ic_b_help_s" src="'
|
||||
. $GLOBALS['pmaThemeImage'] . 'dot.gif" alt="' . __('Documentation') . '" title="' . __('Documentation') . '" /></a>';
|
||||
|
||||
$this->assertEquals($expected, PMA_showPHPDocu($target));
|
||||
}
|
||||
@ -39,4 +39,4 @@ class PMA_showPHPDocu_test extends PHPUnit_Framework_TestCase
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user