From 28c094f50e3c64774e04581a77cb7b1c3de231e0 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Lang Date: Mon, 23 Jun 2008 16:51:13 +0000 Subject: [PATCH] Turn ftp urls into links (#1514). git-svn-id: http://redmine.rubyforge.org/svn/trunk@1577 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- lib/redmine/wiki_formatting.rb | 1 + test/unit/helpers/application_helper_test.rb | 1 + 2 files changed, 2 insertions(+) diff --git a/lib/redmine/wiki_formatting.rb b/lib/redmine/wiki_formatting.rb index 6c8eebbbc..952f636d3 100644 --- a/lib/redmine/wiki_formatting.rb +++ b/lib/redmine/wiki_formatting.rb @@ -129,6 +129,7 @@ module Redmine ) ( (?:https?://)| # protocol spec, or + (?:ftp://)| (?:www\.) # www.* ) ( diff --git a/test/unit/helpers/application_helper_test.rb b/test/unit/helpers/application_helper_test.rb index 9504a8c79..45eb2df90 100644 --- a/test/unit/helpers/application_helper_test.rb +++ b/test/unit/helpers/application_helper_test.rb @@ -36,6 +36,7 @@ class ApplicationHelperTest < HelperTestCase 'http://foo.bar/page?p=1&t=z&s=' => 'http://foo.bar/page?p=1&t=z&s=', 'http://foo.bar/page#125' => 'http://foo.bar/page#125', 'http://foo@www.bar.com' => 'http://foo@www.bar.com', + 'ftp://foo.bar' => 'ftp://foo.bar', } to_test.each { |text, result| assert_equal "

#{result}

", textilizable(text) } end -- 2.39.5