Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add spec for callbacks #154

Merged
merged 1 commit into from
Mar 26, 2018
Merged

Conversation

maiha
Copy link
Contributor

@maiha maiha commented Feb 26, 2018

https://github.com/amberframework/granite-orm/pull/153#discussion_r170689455

an exception thrown in a hook will get swallowed

This PR explicitly specifies why DB::Error is rescued in #save. After this PR, we can detect #153 is well regressed. 😄

In addition, this also ensures the callbacks are fired and its order.
Best regard,

Copy link
Member

@robacarp robacarp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice, thank you

private def _{{name.id}}
history << "{{name.id}}\n"
end
{% end %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hm, this is clever

@faustinoaq
Copy link
Contributor

Fixes #162

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants