Skip to content

Commit

Permalink
Minor code cleanup/updated to latest 3rd party APIs
Browse files Browse the repository at this point in the history
  • Loading branch information
ginty committed May 30, 2016
1 parent 4b3e710 commit 18fd6c1
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 6 deletions.
1 change: 0 additions & 1 deletion .rbenv-version

This file was deleted.

1 change: 0 additions & 1 deletion rakefile → Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ require 'rspec/core/rake_task'
desc "Run specs"
RSpec::Core::RakeTask.new(:spec) do |t|
t.pattern = ("spec/**/*_spec.rb")
t.rcov = true
end

task :default => :spec
Expand Down
2 changes: 1 addition & 1 deletion spec/cranky_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
end

it "raises exception if trait method is undefined" do
expect { Factory.build(:user_by_define, :traits => :manager) }.to raise_error("Invalid trait 'manager'! No method 'apply_trait_manager_to_user_by_define' is defined.")
lambda { Factory.build(:user_by_define, :traits => :manager) }.should raise_error("Invalid trait 'manager'! No method 'apply_trait_manager_to_user_by_define' is defined.")
end

specify "attributes are not assigned when they have the value :skip" do
Expand Down
7 changes: 4 additions & 3 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

require 'cranky'

RSpec.configure do |config|
config.expect_with(:rspec) { |c| c.syntax = :should }
end

class TestClass
attr_accessor :valid

Expand Down Expand Up @@ -96,6 +100,3 @@ def apply_trait_manager_to_user_manually(user)
user.role = :manager
end
end



0 comments on commit 18fd6c1

Please sign in to comment.