Sha256: 616b488bd82d8d246423cc7ad3f95411608c7404025bde26f5b405aae0d0b220

Contents?: true

Size: 671 Bytes

Versions: 1

Compression:

Stored size: 671 Bytes

Contents

require 'spec_helper'
require "cancan/matchers"

describe Ability do
  describe "a user" do
    let(:user) { User.new }
    subject { Ability.new(user)}
    describe "working on Item" do
      before :all do
        @audio = Item.create!(title: 'test audio')
      end
      after :all do
        @audio.destroy
      end
      it { should be_able_to(:create, Item) }
      it { should be_able_to(:edit, @audio) }
      it { should be_able_to(:upload, @audio) }
      it { should be_able_to(:update, @audio) }
      it { should be_able_to(:submit, @audio) }
      it { should be_able_to(:done, @audio) }
      it { should be_able_to(:destroy, @audio) }
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
hydra_mediated-0.0.1 spec/models/ability_spec.rb