cirandas.net

ref: master

plugins/people_block/test/unit/people_block_plugin_test.rb


 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require_relative '../test_helper'

class PeopleBlockPluginTest < ActiveSupport::TestCase

  should "return PeopleBlock in extra_blocks class method" do
    assert PeopleBlockPlugin.extra_blocks.keys.include?(PeopleBlock)
  end

  should "return MembersBlock in extra_blocks class method" do
    assert PeopleBlockPlugin.extra_blocks.keys.include?(MembersBlock)
  end

  should "return FriendsBlock in extra_blocks class method" do
    assert PeopleBlockPlugin.extra_blocks.keys.include?(FriendsBlock)
  end

  should "return false for class method has_admin_url?" do
    refute PeopleBlockPlugin.has_admin_url?
  end

  should "return false for class method stylesheet?" do
    assert PeopleBlockPlugin.new.stylesheet?
  end

end