summaryrefslogtreecommitdiffstats
path: root/spec/spec_helper.rb
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2013-01-08 13:47:54 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2013-01-08 13:47:54 +0100
commit0f9b16f6df09fd835e55bd72898806b27ec93e3f (patch)
tree6ca9686cb788afc8792d2d535063cba0b515a5f4 /spec/spec_helper.rb
parente3c6b822d3fc972bfad1e88ed8461eb928595ae0 (diff)
downloadzorglub-0f9b16f6df09fd835e55bd72898806b27ec93e3f.zip
zorglub-0f9b16f6df09fd835e55bd72898806b27ec93e3f.tar.gz
before_all and after_all accept parameter or proc
Diffstat (limited to 'spec/spec_helper.rb')
-rw-r--r--spec/spec_helper.rb7
1 files changed, 4 insertions, 3 deletions
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index 9369519..262e966 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -103,13 +103,14 @@ class Node3 < Zorglub::Node
@after=0
class << self
attr_accessor :before, :after
+ def post obj
+ @after +=1
+ end
end
before_all do |node|
Node3.before +=1
end
- after_all do |node|
- Node3.after +=1
- end
+ after_all Node3.method(:post)
layout! 'layout-2'
engine! 'engine-2'
def index