lib/machine.rb in aub-machine-1.0.2 vs lib/machine.rb in aub-machine-1.0.3

- old
+ new

@@ -2,8 +2,14 @@ require 'machine/machine' require 'machine/machine_group' require 'machine/sequence' # Shorthand method for building a machine, is an alias for Machine.build(name, attributes) -def Machine(name, attributes={}) - Machine.build(name, attributes) -end \ No newline at end of file +def Machine(name, attributes={}, &block) + Machine.build(name, attributes, &block) +end + +# And the same drill for building a machine and saving the result. +def Machine!(name, attributes={}, &block) + Machine.build!(name, attributes, &block) +end +