percy-capybara 4.1.1 → 4.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/percy.rb +1 -0
- data/lib/version.rb +1 -1
- data/spec/lib/percy/percy_spec.rb +8 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1a484d751642b64d97a1d5b40342b549c464c2ada8c8d6da1c45cdc889a4761b
|
4
|
+
data.tar.gz: 7533abb8bd2ba365757776f6ca46f9864ad517accfabc4b9b26cef020ae5a997
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b8dfffffc550d341b61a691b1302474dd8924d76a98e95e4d957aa9d28d600f227ccf04a4577f679c983eda7a3ab45934744d5a09eb450fbc135416894c4696f
|
7
|
+
data.tar.gz: e0bfb29bfb9be2674679efbeb06573b98eea9f0a152b49d464750ba5b16649712c72913c76ca6af55d274fa4adcd252566f31c8e665b94ad6ddc56ebb90caa3f
|
data/lib/percy.rb
CHANGED
@@ -129,6 +129,7 @@ module Percy
|
|
129
129
|
enable_javascript: :enableJavaScript,
|
130
130
|
min_height: :minHeight,
|
131
131
|
percy_css: :percyCSS,
|
132
|
+
request_headers: :requestHeaders,
|
132
133
|
}.each do |ruby_key, json_key|
|
133
134
|
if options.has_key? ruby_key
|
134
135
|
options[json_key] = options[ruby_key]
|
data/lib/version.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
# coding: utf-8
|
1
2
|
RSpec.describe Percy, type: :feature do
|
2
3
|
TEST_CASE_GLOB = File.join(File.dirname(__FILE__), "./capybara/client/test_data/test-*.html")
|
3
4
|
|
@@ -52,7 +53,12 @@ RSpec.describe Percy, type: :feature do
|
|
52
53
|
|
53
54
|
describe '_keys_to_json' do
|
54
55
|
it 'transforms keys from snake_case to JSON-style' do
|
55
|
-
original = {
|
56
|
+
original = {
|
57
|
+
enable_javascript: true,
|
58
|
+
min_height: 2000,
|
59
|
+
percy_css: "iframe { display: none; }",
|
60
|
+
request_headers: { Authorization: "Basic abc123=" },
|
61
|
+
}
|
56
62
|
transformed = Percy._keys_to_json(original)
|
57
63
|
expect(transformed.has_key? 'enableJavaScript')
|
58
64
|
expect(transformed.has_key? 'percyCSS')
|
@@ -60,6 +66,7 @@ RSpec.describe Percy, type: :feature do
|
|
60
66
|
expect(transformed['enableJavaScript']).to eq(original[:enable_javascript])
|
61
67
|
expect(transformed['minHeight']).to eq(original[:min_height])
|
62
68
|
expect(transformed['percyCSS']).to eq(original[:percy_css])
|
69
|
+
expect(transformed['requestHeaders']).to eq(original[:request_headers])
|
63
70
|
end
|
64
71
|
end
|
65
72
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: percy-capybara
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Perceptual Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10-
|
11
|
+
date: 2019-10-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -144,8 +144,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
144
|
- !ruby/object:Gem::Version
|
145
145
|
version: '0'
|
146
146
|
requirements: []
|
147
|
-
|
148
|
-
rubygems_version: 2.7.7
|
147
|
+
rubygems_version: 3.0.6
|
149
148
|
signing_key:
|
150
149
|
specification_version: 4
|
151
150
|
summary: Percy
|