diaspora/spec/helpers/notifier_helper_spec.rb
2011-09-14 11:23:12 -07:00

20 lines
490 B
Ruby

# Copyright (c) 2010-2011, Diaspora Inc. This file is
# licensed under the Affero General Public License version 3 or later. See
# the COPYRIGHT file.
require 'spec_helper'
describe NotifierHelper do
include MarkdownifyHelper
describe '#comment_message' do
before do
@comment = Factory(:comment)
end
it 'truncates the comment' do
opts = {:length => 2}
comment_message(@comment, opts).should == truncate(@comment.text, opts)
end
end
end