This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Custom rspec matcher for testing CanCan abilities. | |
# Originally inspired by https://github.com/ryanb/cancan/wiki/Testing-Abilities | |
# | |
# Usage: | |
# should have_abilities(:create, Post.new) | |
# should have_abilities([:read, :update], post) | |
# should have_abilities({manage: false, destroy: true}, post) | |
# should have_abilities({create: false}, Post.new) | |
# should not_have_abilities(:update, post) | |
# should not_have_abilities([:update, :destroy], post) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "spec_helper" | |
describe ExampleMailer do | |
describe :new_user do | |
let(:user) { FactoryGirl.create :user } | |
it "sends to the correct addresses" do | |
# :mail is similar to the controller specs 'get', 'post' etc methods | |
mail :new_user, user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'http://rubygems.org' | |
gem 'sass' | |
gem 'coffee-script' | |
gem 'yui-compressor' | |
gem 'handlebars_assets' | |
gem 'sprockets' | |
gem 'rb-fsevent' |