Sha256: 38848c6cda8340e1c068512bd44d93d8797c42b62505f4890ebde56ddc9b755d

Contents?: true

Size: 370 Bytes

Versions: 7

Compression:

Stored size: 370 Bytes

Contents

require "spec_helper"

describe Arrthorizer::Permission do
  describe :grant do
    let(:privilege) { Arrthorizer::Privilege.new(name: "privilege") }
    let(:role) { Arrthorizer::Group.new("role") }

    it "adds the role to the privilege" do
      Arrthorizer::Permission.grant(privilege, to: role)

      expect(privilege).to be_accessible_to(role)
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
arrthorizer-0.4.2 spec/permission/grant_spec.rb
arrthorizer-0.4.1 spec/permission/grant_spec.rb
arrthorizer-0.3.2 spec/permission/grant_spec.rb
arrthorizer-0.3.1 spec/permission/grant_spec.rb
arrthorizer-0.3.0 spec/permission/grant_spec.rb
arrthorizer-0.2.1 spec/permission/grant_spec.rb
arrthorizer-0.2.0 spec/permission/grant_spec.rb