2012-09-05 22:52:49 +02:00
|
|
|
require 'spec_helper'
|
|
|
|
|
|
|
|
describe TreeHelper do
|
|
|
|
describe '#markup?' do
|
2012-09-20 18:11:15 +02:00
|
|
|
%w(textile rdoc org creole mediawiki rst asciidoc pod).each do |type|
|
2012-09-05 22:52:49 +02:00
|
|
|
it "returns true for #{type} files" do
|
|
|
|
markup?("README.#{type}").should be_true
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
it "returns false when given a non-markup filename" do
|
|
|
|
markup?('README.rb').should_not be_true
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|