Sha256: 9baac24bacdff4f210643612bcc4864788d688f097a9c56bd9379d51e2cfa115
Contents?: true
Size: 593 Bytes
Versions: 3
Compression:
Stored size: 593 Bytes
Contents
require 'spec_helper' module CanTango::Ability class Base include CanTango::Ability::Helper::Account def calculate_rules can :edit, Project end end end class MyAccount end class User attr_accessor :account end describe CanTango::Ability::Helper::Account do before do @user = User.new @account = MyAccount.new @user.account = @account end subject do CanTango::Ability::Base.new @user end context 'Ability should have' do describe '#account method' do specify { subject.account.should == @account } end end end
Version data entries
3 entries across 3 versions & 1 rubygems