This file contains hidden or 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
module ActiveRecord | |
module ConnectionAdapters | |
module DatabaseStatements | |
# | |
# Run the normal transaction method; when it's done, check to see if there | |
# is exactly one open transaction. If so, that's the transactional | |
# fixtures transaction; from the model's standpoint, the completed | |
# transaction is the real deal. Send commit callbacks to models. | |
# | |
# If the transaction block raises a Rollback, we need to know, so we don't |
This file contains hidden or 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
module Behaviour | |
def child_class | |
Child | |
end | |
end | |
module Family | |
class Child; end |
This file contains hidden or 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
# No Boom, it was creating the handle first... cause app Boom | |
# This does however, as you say, "Boom" | |
Factory.define :product do |p| | |
p.product_handles do |p| | |
[Factory.build(:product_handle)] | |
end | |
end | |
# Only issue here is that the product has knowledge of the handle... knowledge it need not have. |
This file contains hidden or 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
<<-BUMBLEBEE | |
The bumblebee hovers around an object, | |
looking for a flower with some pollen. | |
It goes from flower to flower, | |
trying each method in order, | |
and when it finds one that isn't empty, | |
it returns it to the hive. | |