From fb29d3927d677693848b25e4b41e974deaa38c93 Mon Sep 17 00:00:00 2001 From: Markus Schirp Date: Wed, 29 Aug 2012 13:38:40 +0200 Subject: [PATCH] Remove idempotent behavior of Zombie.create * Also returns self now (Command Object) --- spec/support/zombie.rb | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/spec/support/zombie.rb b/spec/support/zombie.rb index fd5a923e..45771898 100644 --- a/spec/support/zombie.rb +++ b/spec/support/zombie.rb @@ -1,13 +1,18 @@ module Zombie + # Setup zombie + # + # @return [self] + # + # @api private + # def self.setup - return if defined?(@done) files.each do |path| path = "#{File.expand_path(path, root)}.rb" ast = File.read(path).to_ast zombify(ast, path) - ToSource.to_source(ast.body) end - @done = true + + self end # Return library root directory