lib/acouchi/cucumber.rb in acouchi-0.0.2 vs lib/acouchi/cucumber.rb in acouchi-0.0.3
- old
+ new
@@ -1,16 +1,29 @@
+Before do
+ Acouchi::Cucumber.before
+end
+
+After do
+ Acouchi::Cucumber.after
+end
+
module Acouchi
module Cucumber
def self.page
@page
end
- def self.prepare configuration
- @test_runner = TestRunner.new(configuration)
+ def self.before
+ @test_runner = TestRunner.new(@configuration)
@test_runner.start
@page = Solo.new
- at_exit do
- @test_runner.stop
- end
+ end
+
+ def self.after
+ @test_runner.stop
+ end
+
+ def self.prepare configuration
+ @configuration = configuration
end
end
end