aboutsummaryrefslogtreecommitdiffstats
path: root/spec/helpers/admin_helper_spec.rb
diff options
context:
space:
mode:
authorLouise Crow <louise.crow@gmail.com>2014-05-15 16:09:29 +0100
committerLouise Crow <louise.crow@gmail.com>2014-05-15 16:09:29 +0100
commit26348ce676f7ebbabcc535b2ecf00f99f8fe85c0 (patch)
tree6034dd656a0f9af152f24d6c491b5e61a7190a7d /spec/helpers/admin_helper_spec.rb
parent851ef575cf3c55a3bb194381497b958c2a3ebf1a (diff)
parentb3fa23047bf96bd6a08273c9491ac1ee3b4a3f80 (diff)
Merge branch 'release/0.18' into wdtk
Diffstat (limited to 'spec/helpers/admin_helper_spec.rb')
-rw-r--r--spec/helpers/admin_helper_spec.rb21
1 files changed, 21 insertions, 0 deletions
diff --git a/spec/helpers/admin_helper_spec.rb b/spec/helpers/admin_helper_spec.rb
new file mode 100644
index 000000000..804fcc7fd
--- /dev/null
+++ b/spec/helpers/admin_helper_spec.rb
@@ -0,0 +1,21 @@
+require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
+
+describe AdminHelper do
+
+ include AdminHelper
+
+ describe :comment_visibility do
+
+ it 'shows the status of a visible comment' do
+ comment = Factory.build(:visible_comment)
+ comment_visibility(comment).should == 'Visible'
+ end
+
+ it 'shows the status of a hidden comment' do
+ comment = Factory.build(:hidden_comment)
+ comment_visibility(comment).should == 'Hidden'
+ end
+
+ end
+
+end