Skip to content

Commit

Permalink
Adding tests for absolute urls on script elements.
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Jul 26, 2011
1 parent f140080 commit 9602de8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cake/tests/cases/libs/view/helpers/html.test.php
Original file line number Diff line number Diff line change
Expand Up @@ -592,6 +592,12 @@ function testScript() {
);
$this->assertTags($result, $expected);

$result = $this->Html->script('http://example.com/test.json');
$expected = array(
'script' => array('type' => 'text/javascript', 'src' => 'http://example.com/test.json.js')
);
$this->assertTags($result, $expected);

$result = $this->Html->script('/plugin/js/jquery-1.3.2.js?someparam=foo');
$expected = array(
'script' => array('type' => 'text/javascript', 'src' => '/plugin/js/jquery-1.3.2.js?someparam=foo')
Expand Down

0 comments on commit 9602de8

Please sign in to comment.