mirror of
https://github.com/redmine/redmine.git
synced 2025-11-08 14:26:04 +01:00
use "skip" instead of "if statement" whether Redcarpet is installed at markdown_formatter_test
git-svn-id: http://svn.redmine.org/redmine/trunk@20531 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -20,9 +20,10 @@
|
|||||||
require File.expand_path('../../../../../test_helper', __FILE__)
|
require File.expand_path('../../../../../test_helper', __FILE__)
|
||||||
|
|
||||||
class Redmine::WikiFormatting::MarkdownFormatterTest < ActionView::TestCase
|
class Redmine::WikiFormatting::MarkdownFormatterTest < ActionView::TestCase
|
||||||
if Object.const_defined?(:Redcarpet)
|
|
||||||
|
|
||||||
def setup
|
def setup
|
||||||
|
unless Object.const_defined?(:Redcarpet)
|
||||||
|
skip "Redcarpet is not installed"
|
||||||
|
end
|
||||||
@formatter = Redmine::WikiFormatting::Markdown::Formatter
|
@formatter = Redmine::WikiFormatting::Markdown::Formatter
|
||||||
end
|
end
|
||||||
|
|
||||||
@@ -194,5 +195,4 @@ class Redmine::WikiFormatting::MarkdownFormatterTest < ActionView::TestCase
|
|||||||
assert_equal expected, result.first, "section content did not match"
|
assert_equal expected, result.first, "section content did not match"
|
||||||
assert_equal Digest::MD5.hexdigest(expected), result.last, "section hash did not match"
|
assert_equal Digest::MD5.hexdigest(expected), result.last, "section hash did not match"
|
||||||
end
|
end
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user