webrat 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,9 @@
1
+ == Trunk
2
+
3
+ * Minor enhancements
4
+
5
+ * Use @_webrat_session instance variable instead of @session for Merb integration to avoid collisions
6
+
1
7
  == 0.3.0 / 2008-11-07
2
8
 
3
9
  * Major enhancements
data/lib/webrat.rb CHANGED
@@ -3,7 +3,7 @@ require "rubygems"
3
3
  $LOAD_PATH.unshift(File.expand_path(File.dirname(__FILE__))) unless $LOAD_PATH.include?(File.expand_path(File.dirname(__FILE__)))
4
4
 
5
5
  module Webrat
6
- VERSION = '0.3.0'
6
+ VERSION = '0.3.1'
7
7
 
8
8
  def self.root #:nodoc:
9
9
  defined?(RAILS_ROOT) ? RAILS_ROOT : Merb.root
@@ -5,8 +5,8 @@ module Webrat
5
5
  meths.each do |meth|
6
6
  self.class_eval <<-RUBY
7
7
  def #{meth}(*args, &blk)
8
- @session ||= ::Webrat::MerbSession.new
9
- @session.#{meth}(*args, &blk)
8
+ @_webrat_session ||= ::Webrat::MerbSession.new
9
+ @_webrat_session.#{meth}(*args, &blk)
10
10
  end
11
11
  RUBY
12
12
  end
data/lib/webrat/merb.rb CHANGED
@@ -56,12 +56,12 @@ module Merb
56
56
  module Test
57
57
  module RequestHelper #:nodoc:
58
58
  def request(uri, env = {})
59
- @session ||= Webrat::MerbSession.new
60
- @session.response = @session.request(uri, env)
59
+ @_webrat_session ||= Webrat::MerbSession.new
60
+ @_webrat_session.response = @_webrat_session.request(uri, env)
61
61
  end
62
62
 
63
63
  def follow_redirect
64
- @session.follow_redirect
64
+ @_webrat_session.follow_redirect
65
65
  end
66
66
  end
67
67
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: webrat
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bryan Helmkamp
@@ -110,7 +110,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
110
110
  requirements: []
111
111
 
112
112
  rubyforge_project:
113
- rubygems_version: 1.3.0
113
+ rubygems_version: 1.3.1
114
114
  signing_key:
115
115
  specification_version: 2
116
116
  summary: Webrat. Ruby Acceptance Testing for Web applications