From 72368aa693467c77bf60eff4ff17aa6abb353d6d Mon Sep 17 00:00:00 2001 From: Jonas Nicklas Date: Tue, 30 Oct 2012 14:32:47 +0100 Subject: [PATCH] Move test sessions out of spec helper --- spec/rack_test_spec.rb | 4 ++++ spec/selenium_spec.rb | 4 ++++ spec/spec_helper.rb | 5 ----- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/spec/rack_test_spec.rb b/spec/rack_test_spec.rb index 77278ffc..a356b084 100644 --- a/spec/rack_test_spec.rb +++ b/spec/rack_test_spec.rb @@ -1,5 +1,9 @@ require 'spec_helper' +module TestSessions + RackTest = Capybara::Session.new(:rack_test, TestApp) +end + Capybara::SpecHelper.run_specs TestSessions::RackTest, "RackTest", :skip => [ :js, :screenshot, diff --git a/spec/selenium_spec.rb b/spec/selenium_spec.rb index eb236146..1d53e413 100644 --- a/spec/selenium_spec.rb +++ b/spec/selenium_spec.rb @@ -1,5 +1,9 @@ require 'spec_helper' +module TestSessions + Selenium = Capybara::Session.new(:selenium, TestApp) +end + Capybara::SpecHelper.run_specs TestSessions::Selenium, "selenium", :skip => [ :response_headers, :status_code, diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 8b27ea96..39547b7d 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1,6 +1 @@ require 'capybara/spec/spec_helper' - -module TestSessions - RackTest = Capybara::Session.new(:rack_test, TestApp) - Selenium = Capybara::Session.new(:selenium, TestApp) -end