capybara-user_agent 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/capybara/user_agent/dsl.rb +7 -1
- data/lib/capybara/user_agent/version.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28f5d7b4a00281fba5ee96b64f8aee9ec22f8b03
|
4
|
+
data.tar.gz: 76e8a292deb4d2af7339b137542cd536b0a9ce39
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cfa31efe6ca6056d6f40c1f97f8f56a07418213cdad7a4af21cf5476b217bb1afc5b217ad53ade8c5d2144e3350ce4a4884321f70e2a0ef942e88f6d51ac7d43
|
7
|
+
data.tar.gz: 29ee91c839797c7d39c7dbdb288186e6adb2c5edabd363d7059ba0c585e6bf102bc91c1081152a72d8af5f6ddb243f1695fa4e78f65d9a08c6c6c6ae3c4676ee
|
@@ -6,7 +6,13 @@ module Capybara
|
|
6
6
|
end
|
7
7
|
|
8
8
|
def set_custom_user_agent(user_agent)
|
9
|
-
Capybara.current_session.driver
|
9
|
+
driver = Capybara.current_session.driver
|
10
|
+
|
11
|
+
if driver.respond_to?(:add_headers)
|
12
|
+
driver.add_headers('User-Agent' => user_agent)
|
13
|
+
else
|
14
|
+
driver.header('User-Agent', user_agent)
|
15
|
+
end
|
10
16
|
end
|
11
17
|
end
|
12
18
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capybara-user_agent
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yuki Ito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2014-07-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capybara
|
@@ -66,9 +66,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
66
66
|
version: '0'
|
67
67
|
requirements: []
|
68
68
|
rubyforge_project:
|
69
|
-
rubygems_version: 2.0.
|
69
|
+
rubygems_version: 2.0.3
|
70
70
|
signing_key:
|
71
71
|
specification_version: 4
|
72
72
|
summary: UserAgent DSL on Capybara
|
73
73
|
test_files: []
|
74
|
-
has_rdoc:
|