capybara-mechanize 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -63,12 +63,8 @@ class Capybara::Mechanize::Browser < Capybara::RackTest::Browser
63
63
  end
64
64
  end
65
65
 
66
- def find(format, selector)
67
- if format==:css
68
- dom.css(selector, Capybara::RackTest::CSSHandlers.new)
69
- else
70
- dom.xpath(selector)
71
- end.map { |node| Capybara::Mechanize::Node.new(self, node) }
66
+ def find(selector)
67
+ dom.xpath(selector).map { |node| Capybara::Mechanize::Node.new(self, node) }
72
68
  end
73
69
 
74
70
  attr_reader :agent
@@ -1,5 +1,5 @@
1
1
  module Capybara
2
2
  module Mechanize
3
- VERSION = '1.0.1'
3
+ VERSION = '1.0.2'
4
4
  end
5
5
  end
@@ -13,14 +13,14 @@ describe Capybara::Mechanize::Driver, 'local' do
13
13
  it 'should keep headers on link clicks' do
14
14
  driver = Capybara::RackTest::Driver.new(TestApp, :headers => {'HTTP_FOO' => 'foobar'})
15
15
  driver.visit('/header_links')
16
- driver.find_xpath('.//a').first.click
16
+ driver.find('.//a').first.click
17
17
  driver.html.should include('foobar')
18
18
  end
19
19
 
20
20
  it 'should keep headers on form submit' do
21
21
  driver = Capybara::RackTest::Driver.new(TestApp, :headers => {'HTTP_FOO' => 'foobar'})
22
22
  driver.visit('/header_links')
23
- driver.find_xpath('.//input').first.click
23
+ driver.find('.//input').first.click
24
24
  driver.html.should include('foobar')
25
25
  end
26
26
 
@@ -9,8 +9,7 @@ Capybara::SpecHelper.run_specs TestSessions::Mechanize, "Mechanize", :skip => [
9
9
  :screenshot,
10
10
  :frames,
11
11
  :windows,
12
- :server,
13
- :hover
12
+ :server
14
13
  ]
15
14
 
16
15
  describe Capybara::Session do
@@ -19,8 +19,7 @@ session_describe = Capybara::SpecHelper.run_specs TestSessions::Mechanize, "Mech
19
19
  :screenshot,
20
20
  :frames,
21
21
  :windows,
22
- :server,
23
- :hover
22
+ :server
24
23
  ]
25
24
 
26
25
  session_describe.include_context("remote tests")
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: capybara-mechanize
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-05-02 00:00:00.000000000 Z
12
+ date: 2013-05-07 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: mechanize
@@ -32,23 +32,17 @@ dependencies:
32
32
  requirement: !ruby/object:Gem::Requirement
33
33
  none: false
34
34
  requirements:
35
- - - ~>
36
- - !ruby/object:Gem::Version
37
- version: '2.0'
38
- - - ! '>='
35
+ - - '='
39
36
  - !ruby/object:Gem::Version
40
- version: 2.0.1
37
+ version: 2.0.2
41
38
  type: :runtime
42
39
  prerelease: false
43
40
  version_requirements: !ruby/object:Gem::Requirement
44
41
  none: false
45
42
  requirements:
46
- - - ~>
47
- - !ruby/object:Gem::Version
48
- version: '2.0'
49
- - - ! '>='
43
+ - - '='
50
44
  - !ruby/object:Gem::Version
51
- version: 2.0.1
45
+ version: 2.0.2
52
46
  description: RackTest driver for Capybara, but with remote request support thanks
53
47
  to mechanize
54
48
  email: jeroen@jeevidee.nl