Sha256: fd90519c8b04883b981266889cacd828698c6eb14463ecbe6132bf82eb31faf9

Contents?: true

Size: 399 Bytes

Versions: 9

Compression:

Stored size: 399 Bytes

Contents

require 'test_helper'

class ACLObjectsHashTest < ActionController::TestCase
  setup do
    assert @user = User.create
    assert @user.has_role! :owner, Foo.first_or_create
  end

  test "objects hash preferred to @ivar" do
    assert get :allow, :user_id => @user.id
    assert_response :ok
  end

  test "unauthed for no user" do
    assert get :allow
    assert_response :unauthorized
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
acl9-2.1.2 test/controllers/acl_object_hash_test.rb
acl9-2.1.1 test/controllers/acl_object_hash_test.rb
acl9-2.1.0 test/controllers/acl_object_hash_test.rb
acl9-2.0.0 test/controllers/acl_object_hash_test.rb
acl9-1.3.0 test/controllers/acl_object_hash_test.rb
acl9-1.2.1 test/controllers/acl_object_hash_test.rb
acl9-1.2.0 test/controllers/acl_object_hash_test.rb
acl9-1.1.0 test/controllers/acl_object_hash_test.rb
acl9-1.0.0 test/controllers/acl_object_hash_test.rb