percy-capybara 2.3.1 → 2.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +4 -2
- data/Gemfile.lock +4 -4
- data/lib/percy/capybara/client/builds.rb +1 -1
- data/lib/percy/capybara/loaders/sprockets_loader.rb +1 -0
- data/lib/percy/capybara/version.rb +1 -1
- data/percy-capybara.gemspec +1 -1
- data/spec/lib/percy/capybara/client/builds_spec.rb +5 -4
- data/spec/lib/percy/capybara/client/snapshots_spec.rb +2 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 081b5260631b9369dc527a54f3645002493bf642
|
4
|
+
data.tar.gz: 39f8bb11b13526dee9f3b79ab6539434316a4210
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 44f8f17998d28fbccf9a738b9902d72e06647d4454e76646d3ace5fe3a482df0edd912d8784cfecf6272226222afbc958682efe845df2da72151a72c79b16ca4
|
7
|
+
data.tar.gz: 012a9b6fcec664d54893f74fc8dedac59f14723a126cf1b66a5b51aa7f3552b96ede8bbf64bc3483fc8546e69da957999c8e984f38a069899a23e589b914b758
|
data/.travis.yml
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
percy-capybara (2.3.
|
5
|
-
percy-client (~> 1.
|
4
|
+
percy-capybara (2.3.2)
|
5
|
+
percy-client (~> 1.9)
|
6
6
|
|
7
7
|
GEM
|
8
8
|
remote: https://rubygems.org/
|
@@ -44,7 +44,7 @@ GEM
|
|
44
44
|
guard-compat (~> 1.1)
|
45
45
|
rspec (>= 2.99.0, < 4.0)
|
46
46
|
hashdiff (0.2.3)
|
47
|
-
httpclient (2.8.2.
|
47
|
+
httpclient (2.8.2.4)
|
48
48
|
json (1.8.3)
|
49
49
|
listen (3.0.6)
|
50
50
|
rb-fsevent (>= 0.9.3)
|
@@ -61,7 +61,7 @@ GEM
|
|
61
61
|
notiffany (0.0.8)
|
62
62
|
nenv (~> 0.1)
|
63
63
|
shellany (~> 0.0)
|
64
|
-
percy-client (1.
|
64
|
+
percy-client (1.9.0)
|
65
65
|
faraday (>= 0.9)
|
66
66
|
httpclient (>= 2.6)
|
67
67
|
pry (0.10.3)
|
@@ -65,7 +65,7 @@ module Percy
|
|
65
65
|
resource = build_resources.find { |r| r.sha == sha }
|
66
66
|
content = resource.content || File.read(resource.path)
|
67
67
|
client.upload_resource(current_build['data']['id'], content)
|
68
|
-
if i %
|
68
|
+
if i % 10 == 0
|
69
69
|
puts "[percy] Uploading #{i+1} of #{new_build_resources.length} new resources..."
|
70
70
|
end
|
71
71
|
end
|
data/percy-capybara.gemspec
CHANGED
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
|
|
18
18
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
19
|
spec.require_paths = ['lib']
|
20
20
|
|
21
|
-
spec.add_dependency 'percy-client', '~> 1.
|
21
|
+
spec.add_dependency 'percy-client', '~> 1.9'
|
22
22
|
|
23
23
|
spec.add_development_dependency 'bundler', '~> 1.7'
|
24
24
|
spec.add_development_dependency 'rake', '~> 10.0'
|
@@ -1,6 +1,7 @@
|
|
1
1
|
RSpec.describe Percy::Capybara::Client::Builds do
|
2
2
|
let(:enabled) { true }
|
3
3
|
let(:capybara_client) { Percy::Capybara::Client.new(enabled: enabled) }
|
4
|
+
let(:builds_api_url) { "https://percy.io/api/v1/repos/#{Percy::Client::Environment.repo}/builds/" }
|
4
5
|
|
5
6
|
describe '#initialize_build', type: :feature, js: true do
|
6
7
|
before(:each) { setup_sprockets(capybara_client) }
|
@@ -18,7 +19,7 @@ RSpec.describe Percy::Capybara::Client::Builds do
|
|
18
19
|
'type' => 'builds',
|
19
20
|
},
|
20
21
|
}
|
21
|
-
stub_request(:post,
|
22
|
+
stub_request(:post, builds_api_url)
|
22
23
|
.to_return(status: 201, body: mock_response.to_json)
|
23
24
|
expect(capybara_client.initialize_build).to eq(mock_response)
|
24
25
|
end
|
@@ -43,7 +44,7 @@ RSpec.describe Percy::Capybara::Client::Builds do
|
|
43
44
|
},
|
44
45
|
}
|
45
46
|
# Stub create build.
|
46
|
-
build_stub = stub_request(:post,
|
47
|
+
build_stub = stub_request(:post, builds_api_url)
|
47
48
|
.to_return(status: 201, body: mock_response.to_json)
|
48
49
|
|
49
50
|
# Stub resource upload.
|
@@ -81,7 +82,7 @@ RSpec.describe Percy::Capybara::Client::Builds do
|
|
81
82
|
},
|
82
83
|
}
|
83
84
|
# Stub create build.
|
84
|
-
build_stub = stub_request(:post,
|
85
|
+
build_stub = stub_request(:post, builds_api_url)
|
85
86
|
.to_return(status: 201, body: mock_response.to_json)
|
86
87
|
|
87
88
|
# Stub resource upload.
|
@@ -156,7 +157,7 @@ RSpec.describe Percy::Capybara::Client::Builds do
|
|
156
157
|
'type' => 'builds',
|
157
158
|
},
|
158
159
|
}
|
159
|
-
stub_request(:post,
|
160
|
+
stub_request(:post, builds_api_url)
|
160
161
|
.to_return(status: 201, body: mock_response.to_json)
|
161
162
|
capybara_client.initialize_build
|
162
163
|
|
@@ -46,7 +46,8 @@ RSpec.describe Percy::Capybara::Client::Snapshots, type: :feature do
|
|
46
46
|
before :each do
|
47
47
|
visit '/'
|
48
48
|
loader # Force evaluation now.
|
49
|
-
|
49
|
+
repo = Percy::Client::Environment.repo
|
50
|
+
stub_request(:post, "https://percy.io/api/v1/repos/#{repo}/builds/")
|
50
51
|
.to_return(status: 201, body: mock_build_response.to_json)
|
51
52
|
stub_request(:post, 'https://percy.io/api/v1/builds/123/snapshots/')
|
52
53
|
.to_return(status: 201, body: mock_snapshot_response.to_json)
|
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: 2.3.
|
4
|
+
version: 2.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Perceptual Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: percy-client
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '1.
|
19
|
+
version: '1.9'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '1.
|
26
|
+
version: '1.9'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: bundler
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -249,7 +249,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
249
249
|
version: '0'
|
250
250
|
requirements: []
|
251
251
|
rubyforge_project:
|
252
|
-
rubygems_version: 2.
|
252
|
+
rubygems_version: 2.6.7
|
253
253
|
signing_key:
|
254
254
|
specification_version: 4
|
255
255
|
summary: Percy::Capybara
|