diff options
author | Eric Barnes <eric@ericlbarnes.com> | 2011-11-27 20:12:46 +0100 |
---|---|---|
committer | Eric Barnes <eric@ericlbarnes.com> | 2011-11-27 20:12:46 +0100 |
commit | d90e1a0fb541ee94459a20cf8b0726aebaec9692 (patch) | |
tree | c4ed3eee3bf4dcd9bc63ee2ccf751bb734ee726e /tests/codeigniter | |
parent | c836978e257bdba0827ab7506c890c6b7b223879 (diff) |
Added unit test to confirm pull request #675
Diffstat (limited to 'tests/codeigniter')
-rw-r--r-- | tests/codeigniter/helpers/url_helper_test.php | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/codeigniter/helpers/url_helper_test.php b/tests/codeigniter/helpers/url_helper_test.php index 30ba4a417..51a8cc7c0 100644 --- a/tests/codeigniter/helpers/url_helper_test.php +++ b/tests/codeigniter/helpers/url_helper_test.php @@ -47,6 +47,21 @@ class Url_helper_test extends CI_TestCase $strings = array( 'www.codeigniter.com test' => '<a href="http://www.codeigniter.com">http://www.codeigniter.com</a> test', 'This is my noreply@codeigniter.com test' => 'This is my noreply@codeigniter.com test', + '<br />www.google.com' => '<br /><a href="http://www.google.com">http://www.google.com</a>', + ); + + foreach ($strings as $in => $out) + { + $this->assertEquals($out, auto_link($in, 'url')); + } + } + + // -------------------------------------------------------------------- + + public function test_pull_675() + { + $strings = array( + '<br />www.google.com' => '<br /><a href="http://www.google.com">http://www.google.com</a>', ); foreach ($strings as $in => $out) |