test/unit/models/user_test.rb in browsercms_s3-3.0.4 vs test/unit/models/user_test.rb in browsercms_s3-3.0.5

- old
+ new

@@ -70,11 +70,11 @@ end class UserPermissionsTest < ActiveSupport::TestCase def setup @user = Factory(:user) - @guest_group = Group.first(:conditions => {:code => "guest"}) + @guest_group = Group.guest end def test_user_permissions @have = Factory(:permission, :name => "do something the group has permission to do") @havenot = Factory(:permission, :name => "do something the group does not have permission to do") @@ -208,10 +208,10 @@ end class GuestUserTest < ActiveSupport::TestCase def setup @user = User.guest - @guest_group = Group.with_code("guest").first + @guest_group = Group.guest @public_page = Factory(:page, :section => root_section) @protected_section = Factory(:section, :parent => root_section) @protected_page = Factory(:page, :section => @protected_section) end