capybara-headless_chrome 0.6.1 → 0.6.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +12 -0
- data/gemfiles/capybara_2.gemfile.lock +6 -9
- data/gemfiles/capybara_3.gemfile.lock +6 -9
- data/gemfiles/latest.gemfile.lock +14 -13
- data/gemfiles/rails_5.0.gemfile.lock +12 -11
- data/gemfiles/rails_5.1.gemfile.lock +12 -11
- data/gemfiles/rails_5.2.gemfile.lock +12 -11
- data/lib/capybara/headless_chrome/driver.rb +6 -0
- data/lib/capybara/headless_chrome/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 16260f8e62fe816ce512aa2983a46428976d9d55
|
4
|
+
data.tar.gz: 76462eca89f28e2bfea02ec9f92617223b542e1d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bbd3cad99fbe8efe949ecb6b319c380aa49b140f7bff78477df6663cff094c279cfee3a3c3c86153ff76ba62f968b1beeb2c9a6ee551b36ec3ab4b3ef45cf3ae
|
7
|
+
data.tar.gz: e75a08008046d6642a2b57390a40615c2f6f8d2eb66da5c421142d520f37f121497a7f52b8208282ed6b5c611d7de8d794cbeb989b42cdf7e3aaf93d66102586
|
data/README.md
CHANGED
@@ -9,6 +9,18 @@ A nice and tidy Capybara driver for headless Chrome. Even supports file download
|
|
9
9
|
|
10
10
|
Just `require "capybara/headless_chrome"` somewhere in your test setup. This will register the `:chrome` driver, and make it Capybara's default.
|
11
11
|
|
12
|
+
#### Options
|
13
|
+
|
14
|
+
If you want to change some of the options Chrome is started with, just reregister the driver:
|
15
|
+
|
16
|
+
```ruby
|
17
|
+
Capybara.register_driver :chrome do |app|
|
18
|
+
Capybara::HeadlessChrome::Driver.new(app, lang: "es_MX", headless: false, window_size: [1024,768])
|
19
|
+
end
|
20
|
+
```
|
21
|
+
|
22
|
+
Consult https://peter.sh/experiments/chromium-command-line-switches/ for a list of options. Although these are command-line options, conversion from a Ruby hash works as you would expect. E.g. `headless: true` works out to `--headless`, `window_size: [1024,768]` works out to `--window-size=1024,768`, etc.
|
23
|
+
|
12
24
|
### Working with Downloaded Files
|
13
25
|
|
14
26
|
The Capybara session is extended with a single `#downloads` method that provides access to files downloaded during the session.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -22,13 +22,11 @@ GEM
|
|
22
22
|
rack (>= 1.0.0)
|
23
23
|
rack-test (>= 0.5.4)
|
24
24
|
xpath (>= 2.0, < 4.0)
|
25
|
-
childprocess (0.
|
26
|
-
|
25
|
+
childprocess (1.0.1)
|
26
|
+
rake (< 13.0)
|
27
27
|
diff-lcs (1.3)
|
28
|
-
ffi (1.10.0)
|
29
28
|
mini_mime (1.0.1)
|
30
29
|
mini_portile2 (2.4.0)
|
31
|
-
net_http_ssl_fix (0.0.10)
|
32
30
|
nokogiri (1.10.2)
|
33
31
|
mini_portile2 (~> 2.4.0)
|
34
32
|
public_suffix (3.0.3)
|
@@ -50,12 +48,11 @@ GEM
|
|
50
48
|
rspec-support (~> 3.8.0)
|
51
49
|
rspec-support (3.8.0)
|
52
50
|
rubyzip (1.2.2)
|
53
|
-
selenium-webdriver (3.
|
54
|
-
childprocess (
|
51
|
+
selenium-webdriver (3.142.2)
|
52
|
+
childprocess (>= 0.5, < 2.0)
|
55
53
|
rubyzip (~> 1.2, >= 1.2.2)
|
56
54
|
thor (0.20.3)
|
57
|
-
webdrivers (3.
|
58
|
-
net_http_ssl_fix
|
55
|
+
webdrivers (3.9.2)
|
59
56
|
nokogiri (~> 1.6)
|
60
57
|
rubyzip (~> 1.0)
|
61
58
|
selenium-webdriver (~> 3.0)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -23,13 +23,11 @@ GEM
|
|
23
23
|
rack-test (>= 0.6.3)
|
24
24
|
regexp_parser (~> 1.2)
|
25
25
|
xpath (~> 3.2)
|
26
|
-
childprocess (0.
|
27
|
-
|
26
|
+
childprocess (1.0.1)
|
27
|
+
rake (< 13.0)
|
28
28
|
diff-lcs (1.3)
|
29
|
-
ffi (1.10.0)
|
30
29
|
mini_mime (1.0.1)
|
31
30
|
mini_portile2 (2.4.0)
|
32
|
-
net_http_ssl_fix (0.0.10)
|
33
31
|
nokogiri (1.10.2)
|
34
32
|
mini_portile2 (~> 2.4.0)
|
35
33
|
public_suffix (3.0.3)
|
@@ -52,12 +50,11 @@ GEM
|
|
52
50
|
rspec-support (~> 3.8.0)
|
53
51
|
rspec-support (3.8.0)
|
54
52
|
rubyzip (1.2.2)
|
55
|
-
selenium-webdriver (3.
|
56
|
-
childprocess (
|
53
|
+
selenium-webdriver (3.142.2)
|
54
|
+
childprocess (>= 0.5, < 2.0)
|
57
55
|
rubyzip (~> 1.2, >= 1.2.2)
|
58
56
|
thor (0.20.3)
|
59
|
-
webdrivers (3.
|
60
|
-
net_http_ssl_fix
|
57
|
+
webdrivers (3.9.2)
|
61
58
|
nokogiri (~> 1.6)
|
62
59
|
rubyzip (~> 1.0)
|
63
60
|
selenium-webdriver (~> 3.0)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -15,29 +15,29 @@ GEM
|
|
15
15
|
rake
|
16
16
|
thor (>= 0.14.0)
|
17
17
|
byebug (11.0.1)
|
18
|
-
capybara (3.
|
18
|
+
capybara (3.20.0)
|
19
19
|
addressable
|
20
20
|
mini_mime (>= 0.1.3)
|
21
21
|
nokogiri (~> 1.8)
|
22
22
|
rack (>= 1.6.0)
|
23
23
|
rack-test (>= 0.6.3)
|
24
24
|
regexp_parser (~> 1.2)
|
25
|
+
uglifier
|
25
26
|
xpath (~> 3.2)
|
26
|
-
childprocess (0.
|
27
|
-
|
27
|
+
childprocess (1.0.1)
|
28
|
+
rake (< 13.0)
|
28
29
|
diff-lcs (1.3)
|
29
|
-
|
30
|
+
execjs (2.7.0)
|
30
31
|
mini_mime (1.0.1)
|
31
32
|
mini_portile2 (2.4.0)
|
32
|
-
|
33
|
-
nokogiri (1.10.2)
|
33
|
+
nokogiri (1.10.3)
|
34
34
|
mini_portile2 (~> 2.4.0)
|
35
35
|
public_suffix (3.0.3)
|
36
|
-
rack (2.0.
|
36
|
+
rack (2.0.7)
|
37
37
|
rack-test (1.1.0)
|
38
38
|
rack (>= 1.0, < 3)
|
39
39
|
rake (10.5.0)
|
40
|
-
regexp_parser (1.
|
40
|
+
regexp_parser (1.5.0)
|
41
41
|
rspec (3.8.0)
|
42
42
|
rspec-core (~> 3.8.0)
|
43
43
|
rspec-expectations (~> 3.8.0)
|
@@ -52,12 +52,13 @@ GEM
|
|
52
52
|
rspec-support (~> 3.8.0)
|
53
53
|
rspec-support (3.8.0)
|
54
54
|
rubyzip (1.2.2)
|
55
|
-
selenium-webdriver (3.
|
56
|
-
childprocess (
|
55
|
+
selenium-webdriver (3.142.2)
|
56
|
+
childprocess (>= 0.5, < 2.0)
|
57
57
|
rubyzip (~> 1.2, >= 1.2.2)
|
58
58
|
thor (0.20.3)
|
59
|
-
|
60
|
-
|
59
|
+
uglifier (4.1.20)
|
60
|
+
execjs (>= 0.3.0, < 3)
|
61
|
+
webdrivers (3.9.2)
|
61
62
|
nokogiri (~> 1.6)
|
62
63
|
rubyzip (~> 1.0)
|
63
64
|
selenium-webdriver (~> 3.0)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -54,21 +54,22 @@ GEM
|
|
54
54
|
arel (7.1.4)
|
55
55
|
builder (3.2.3)
|
56
56
|
byebug (11.0.1)
|
57
|
-
capybara (3.
|
57
|
+
capybara (3.20.0)
|
58
58
|
addressable
|
59
59
|
mini_mime (>= 0.1.3)
|
60
60
|
nokogiri (~> 1.8)
|
61
61
|
rack (>= 1.6.0)
|
62
62
|
rack-test (>= 0.6.3)
|
63
63
|
regexp_parser (~> 1.2)
|
64
|
+
uglifier
|
64
65
|
xpath (~> 3.2)
|
65
|
-
childprocess (0.
|
66
|
-
|
66
|
+
childprocess (1.0.1)
|
67
|
+
rake (< 13.0)
|
67
68
|
concurrent-ruby (1.1.5)
|
68
69
|
crass (1.0.4)
|
69
70
|
diff-lcs (1.3)
|
70
71
|
erubis (2.7.0)
|
71
|
-
|
72
|
+
execjs (2.7.0)
|
72
73
|
globalid (0.4.2)
|
73
74
|
activesupport (>= 4.2.0)
|
74
75
|
i18n (1.6.0)
|
@@ -82,7 +83,6 @@ GEM
|
|
82
83
|
mini_mime (1.0.1)
|
83
84
|
mini_portile2 (2.4.0)
|
84
85
|
minitest (5.11.3)
|
85
|
-
net_http_ssl_fix (0.0.10)
|
86
86
|
nio4r (2.3.1)
|
87
87
|
nokogiri (1.10.2)
|
88
88
|
mini_portile2 (~> 2.4.0)
|
@@ -114,7 +114,7 @@ GEM
|
|
114
114
|
rake (>= 0.8.7)
|
115
115
|
thor (>= 0.18.1, < 2.0)
|
116
116
|
rake (10.5.0)
|
117
|
-
regexp_parser (1.
|
117
|
+
regexp_parser (1.5.0)
|
118
118
|
rspec (3.8.0)
|
119
119
|
rspec-core (~> 3.8.0)
|
120
120
|
rspec-expectations (~> 3.8.0)
|
@@ -129,8 +129,8 @@ GEM
|
|
129
129
|
rspec-support (~> 3.8.0)
|
130
130
|
rspec-support (3.8.0)
|
131
131
|
rubyzip (1.2.2)
|
132
|
-
selenium-webdriver (3.
|
133
|
-
childprocess (
|
132
|
+
selenium-webdriver (3.142.2)
|
133
|
+
childprocess (>= 0.5, < 2.0)
|
134
134
|
rubyzip (~> 1.2, >= 1.2.2)
|
135
135
|
sprockets (3.7.2)
|
136
136
|
concurrent-ruby (~> 1.0)
|
@@ -144,8 +144,9 @@ GEM
|
|
144
144
|
thread_safe (0.3.6)
|
145
145
|
tzinfo (1.2.5)
|
146
146
|
thread_safe (~> 0.1)
|
147
|
-
|
148
|
-
|
147
|
+
uglifier (4.1.20)
|
148
|
+
execjs (>= 0.3.0, < 3)
|
149
|
+
webdrivers (3.9.2)
|
149
150
|
nokogiri (~> 1.6)
|
150
151
|
rubyzip (~> 1.0)
|
151
152
|
selenium-webdriver (~> 3.0)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -54,21 +54,22 @@ GEM
|
|
54
54
|
arel (8.0.0)
|
55
55
|
builder (3.2.3)
|
56
56
|
byebug (11.0.1)
|
57
|
-
capybara (3.
|
57
|
+
capybara (3.20.0)
|
58
58
|
addressable
|
59
59
|
mini_mime (>= 0.1.3)
|
60
60
|
nokogiri (~> 1.8)
|
61
61
|
rack (>= 1.6.0)
|
62
62
|
rack-test (>= 0.6.3)
|
63
63
|
regexp_parser (~> 1.2)
|
64
|
+
uglifier
|
64
65
|
xpath (~> 3.2)
|
65
|
-
childprocess (0.
|
66
|
-
|
66
|
+
childprocess (1.0.1)
|
67
|
+
rake (< 13.0)
|
67
68
|
concurrent-ruby (1.1.5)
|
68
69
|
crass (1.0.4)
|
69
70
|
diff-lcs (1.3)
|
70
71
|
erubi (1.8.0)
|
71
|
-
|
72
|
+
execjs (2.7.0)
|
72
73
|
globalid (0.4.2)
|
73
74
|
activesupport (>= 4.2.0)
|
74
75
|
i18n (1.6.0)
|
@@ -82,7 +83,6 @@ GEM
|
|
82
83
|
mini_mime (1.0.1)
|
83
84
|
mini_portile2 (2.4.0)
|
84
85
|
minitest (5.11.3)
|
85
|
-
net_http_ssl_fix (0.0.10)
|
86
86
|
nio4r (2.3.1)
|
87
87
|
nokogiri (1.10.2)
|
88
88
|
mini_portile2 (~> 2.4.0)
|
@@ -114,7 +114,7 @@ GEM
|
|
114
114
|
rake (>= 0.8.7)
|
115
115
|
thor (>= 0.18.1, < 2.0)
|
116
116
|
rake (10.5.0)
|
117
|
-
regexp_parser (1.
|
117
|
+
regexp_parser (1.5.0)
|
118
118
|
rspec (3.8.0)
|
119
119
|
rspec-core (~> 3.8.0)
|
120
120
|
rspec-expectations (~> 3.8.0)
|
@@ -129,8 +129,8 @@ GEM
|
|
129
129
|
rspec-support (~> 3.8.0)
|
130
130
|
rspec-support (3.8.0)
|
131
131
|
rubyzip (1.2.2)
|
132
|
-
selenium-webdriver (3.
|
133
|
-
childprocess (
|
132
|
+
selenium-webdriver (3.142.2)
|
133
|
+
childprocess (>= 0.5, < 2.0)
|
134
134
|
rubyzip (~> 1.2, >= 1.2.2)
|
135
135
|
sprockets (3.7.2)
|
136
136
|
concurrent-ruby (~> 1.0)
|
@@ -143,8 +143,9 @@ GEM
|
|
143
143
|
thread_safe (0.3.6)
|
144
144
|
tzinfo (1.2.5)
|
145
145
|
thread_safe (~> 0.1)
|
146
|
-
|
147
|
-
|
146
|
+
uglifier (4.1.20)
|
147
|
+
execjs (>= 0.3.0, < 3)
|
148
|
+
webdrivers (3.9.2)
|
148
149
|
nokogiri (~> 1.6)
|
149
150
|
rubyzip (~> 1.0)
|
150
151
|
selenium-webdriver (~> 3.0)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: ..
|
3
3
|
specs:
|
4
|
-
capybara-headless_chrome (0.6.
|
4
|
+
capybara-headless_chrome (0.6.2)
|
5
5
|
capybara
|
6
6
|
webdrivers
|
7
7
|
|
@@ -58,21 +58,22 @@ GEM
|
|
58
58
|
arel (9.0.0)
|
59
59
|
builder (3.2.3)
|
60
60
|
byebug (11.0.1)
|
61
|
-
capybara (3.
|
61
|
+
capybara (3.20.0)
|
62
62
|
addressable
|
63
63
|
mini_mime (>= 0.1.3)
|
64
64
|
nokogiri (~> 1.8)
|
65
65
|
rack (>= 1.6.0)
|
66
66
|
rack-test (>= 0.6.3)
|
67
67
|
regexp_parser (~> 1.2)
|
68
|
+
uglifier
|
68
69
|
xpath (~> 3.2)
|
69
|
-
childprocess (0.
|
70
|
-
|
70
|
+
childprocess (1.0.1)
|
71
|
+
rake (< 13.0)
|
71
72
|
concurrent-ruby (1.1.5)
|
72
73
|
crass (1.0.4)
|
73
74
|
diff-lcs (1.3)
|
74
75
|
erubi (1.8.0)
|
75
|
-
|
76
|
+
execjs (2.7.0)
|
76
77
|
globalid (0.4.2)
|
77
78
|
activesupport (>= 4.2.0)
|
78
79
|
i18n (1.6.0)
|
@@ -89,7 +90,6 @@ GEM
|
|
89
90
|
mini_mime (1.0.1)
|
90
91
|
mini_portile2 (2.4.0)
|
91
92
|
minitest (5.11.3)
|
92
|
-
net_http_ssl_fix (0.0.10)
|
93
93
|
nio4r (2.3.1)
|
94
94
|
nokogiri (1.10.2)
|
95
95
|
mini_portile2 (~> 2.4.0)
|
@@ -122,7 +122,7 @@ GEM
|
|
122
122
|
rake (>= 0.8.7)
|
123
123
|
thor (>= 0.19.0, < 2.0)
|
124
124
|
rake (10.5.0)
|
125
|
-
regexp_parser (1.
|
125
|
+
regexp_parser (1.5.0)
|
126
126
|
rspec (3.8.0)
|
127
127
|
rspec-core (~> 3.8.0)
|
128
128
|
rspec-expectations (~> 3.8.0)
|
@@ -137,8 +137,8 @@ GEM
|
|
137
137
|
rspec-support (~> 3.8.0)
|
138
138
|
rspec-support (3.8.0)
|
139
139
|
rubyzip (1.2.2)
|
140
|
-
selenium-webdriver (3.
|
141
|
-
childprocess (
|
140
|
+
selenium-webdriver (3.142.2)
|
141
|
+
childprocess (>= 0.5, < 2.0)
|
142
142
|
rubyzip (~> 1.2, >= 1.2.2)
|
143
143
|
sprockets (3.7.2)
|
144
144
|
concurrent-ruby (~> 1.0)
|
@@ -151,8 +151,9 @@ GEM
|
|
151
151
|
thread_safe (0.3.6)
|
152
152
|
tzinfo (1.2.5)
|
153
153
|
thread_safe (~> 0.1)
|
154
|
-
|
155
|
-
|
154
|
+
uglifier (4.1.20)
|
155
|
+
execjs (>= 0.3.0, < 3)
|
156
|
+
webdrivers (3.9.2)
|
156
157
|
nokogiri (~> 1.6)
|
157
158
|
rubyzip (~> 1.0)
|
158
159
|
selenium-webdriver (~> 3.0)
|
@@ -2,6 +2,12 @@ require "webdrivers"
|
|
2
2
|
require "capybara"
|
3
3
|
require "capybara/headless_chrome/downloads"
|
4
4
|
|
5
|
+
# silence warning with webdrivers ~>3.9
|
6
|
+
webdrivers_version = Gem.loaded_specs["webdrivers"].version
|
7
|
+
if webdrivers_version >= Gem::Version.new("3.9") && webdrivers_version < Gem::Version.new("4.0")
|
8
|
+
Webdrivers.cache_time = 1.day
|
9
|
+
end
|
10
|
+
|
5
11
|
module Capybara
|
6
12
|
module HeadlessChrome
|
7
13
|
class Driver < Capybara::Selenium::Driver
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capybara-headless_chrome
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Micah Geisel
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-05-
|
11
|
+
date: 2019-05-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: webdrivers
|