1
0
Fork 0
mirror of https://github.com/aasm/aasm synced 2023-03-27 23:22:41 -04:00

Clean up comments

This commit is contained in:
Chris Woodrich 2015-10-22 18:13:11 -07:00
parent 53d333cfc5
commit 892e2bc05d
2 changed files with 1 additions and 3 deletions

View file

@ -23,7 +23,7 @@ Dir[File.dirname(__FILE__) + "/spec_helpers/**/*.rb"].sort.each { |f| require Fi
# example model classes
Dir[File.dirname(__FILE__) + "/models/*.rb"].sort.each { |f| require File.expand_path(f) }
def safe_error(callback = nil)
def safe_error(callback = nil) # Need callack to maintain scope for Proc testing
error = nil
begin
yield

View file

@ -285,8 +285,6 @@ describe 'event callbacks' do
it 'should call it when transition failed for bang fire' do
expect(@foo).to receive(:aasm_event_failed).with(:null, :open)
#expect {@foo.null!}.to raise_error(AASM::InvalidTransition)
error = safe_error { @foo.null! }
expect(error.class).to eq AASM::InvalidTransition