Commit 50f70f556cfc1f4b1ddac2dc32094e0cb1dab992

Authored by AntonioTerceiro
1 parent 9dd0a1ec

ActionItem8: testing acts_as_configurable basics

git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@54 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing 1 changed file with 9 additions and 0 deletions   Show diff stats
test/unit/virtual_community_test.rb
... ... @@ -22,4 +22,13 @@ class VirtualCommunityTest < Test::Unit::TestCase
22 22 assert_equal vc, VirtualCommunity.default
23 23 end
24 24  
  25 + def test_acts_as_configurable
  26 + vc = VirtualCommunity.new(:name => 'Testing VirtualCommunity')
  27 + assert_kind_of Array, vc.settings
  28 + vc.settings[:some_setting] = 1
  29 + assert vc.save
  30 + assert_equal 1, vc.settings[:some_setting]
  31 + assert_kind_of ConfigurableSetting, vc.settings.first
  32 + end
  33 +
25 34 end
... ...