Created
April 16, 2019 10:47
-
-
Save susanwere/43d1a9d6b11b9edab3713d775e407ef1 to your computer and use it in GitHub Desktop.
before hook for model
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
before do | |
@invalid_product = Product.new(title: '', description: '', price: '') | |
@valid_product = Product.new(title: 'One', description: 'description one', price: '100.00') | |
@invalid_price = Product.new(title: 'One', description: 'description one', price: '0.00') | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment