1 <pre id="sh_007_collapse_a" class="brush: groovy; collapse: true" title="This is a title for collapsed block">
3 * Returns an Image object that can then be painted on the screen.
4 * The url argument must specify an absolute {@link URL}. The name
5 * argument is a specifier that is relative to the url argument.
7 * @param url an absolute URL giving the base location of the image
8 * @param name the location of the image, relative to the url argument
9 * @return the image at the specified URL
14 <pre id="sh_007_collapse_b" class="brush: groovy; collapse: true">
16 * Returns an Image object that can then be painted on the screen.
17 * The url argument must specify an absolute {@link URL}. The name
18 * argument is a specifier that is relative to the url argument.
20 * @param url an absolute URL giving the base location of the image
21 * @param name the location of the image, relative to the url argument
22 * @return the image at the specified URL
27 <script type="text/javascript">
32 module('007_collapse');
34 test('collapsed block with title', function()
36 $sh = $('#sh_007_collapse_a');
42 var $title = $sh.find('.toolbar a.toolbar_item.command_expandSource');
43 ok($title.length == 1, 'Expand present');
44 equal($title.text(), 'This is a title for collapsed block', 'Expand text');
47 test('collapsed block without title', function()
49 $sh = $('#sh_007_collapse_b');
55 var $title = $sh.find('.toolbar a.toolbar_item.command_expandSource');
56 ok($title.length == 1, 'Expand present');
57 equal($title.text(), SyntaxHighlighter.config.strings.expandSource, 'Expand text');