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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 12bada606db24ecb479120df317bad285e7b8bb9
4
- data.tar.gz: 078e75d9078652686011fc68c1002487b0b534d7
3
+ metadata.gz: 081b5260631b9369dc527a54f3645002493bf642
4
+ data.tar.gz: 39f8bb11b13526dee9f3b79ab6539434316a4210
5
5
  SHA512:
6
- metadata.gz: c5832b7d3adac95504cadef29bf2518941ec16746510983055abd1779086379384cbbfb4a41aa2cf9bf56fc470d9191f5e446de801bda37bbc974034fa3ed6a8
7
- data.tar.gz: 729aa019732cc735111a3b48ace21e2087b39d1737c64fc5b7a0c81392583e5502ce481a2d4efabbab433c35c1586033122a46b6158a97ad9172631bb333716f
6
+ metadata.gz: 44f8f17998d28fbccf9a738b9902d72e06647d4454e76646d3ace5fe3a482df0edd912d8784cfecf6272226222afbc958682efe845df2da72151a72c79b16ca4
7
+ data.tar.gz: 012a9b6fcec664d54893f74fc8dedac59f14723a126cf1b66a5b51aa7f3552b96ede8bbf64bc3483fc8546e69da957999c8e984f38a069899a23e589b914b758
data/.travis.yml CHANGED
@@ -3,9 +3,11 @@ sudo: false
3
3
  cache: bundler
4
4
  rvm:
5
5
  - 1.9.3
6
- - 2.1.1
7
- - 2.2.2
6
+ - 2.2
8
7
  - ruby-head
8
+ matrix:
9
+ allow_failures:
10
+ - rvm: ruby-head
9
11
  before_install:
10
12
  - gem update bundler
11
13
  script: xvfb-run bundle exec rspec
data/Gemfile.lock CHANGED
@@ -1,8 +1,8 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- percy-capybara (2.3.1)
5
- percy-client (~> 1.4)
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.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.6.0)
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 % 50 == 0
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
@@ -15,6 +15,7 @@ module Percy
15
15
 
16
16
  SKIP_RESOURCE_EXTENSIONS = [
17
17
  '.map', # Ignore source maps.
18
+ '.gz', # Ignore gzipped files.
18
19
  ]
19
20
  MAX_FILESIZE_BYTES = 15 * 1024**2 # 15 MB.
20
21
 
@@ -1,5 +1,5 @@
1
1
  module Percy
2
2
  module Capybara
3
- VERSION = '2.3.1'
3
+ VERSION = '2.3.2'
4
4
  end
5
5
  end
@@ -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.4'
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, 'https://percy.io/api/v1/repos/percy/percy-capybara/builds/')
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, 'https://percy.io/api/v1/repos/percy/percy-capybara/builds/')
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, 'https://percy.io/api/v1/repos/percy/percy-capybara/builds/')
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, 'https://percy.io/api/v1/repos/percy/percy-capybara/builds/')
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
- stub_request(:post, 'https://percy.io/api/v1/repos/percy/percy-capybara/builds/')
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.1
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-08-22 00:00:00.000000000 Z
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.4'
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.4'
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.4.5.1
252
+ rubygems_version: 2.6.7
253
253
  signing_key:
254
254
  specification_version: 4
255
255
  summary: Percy::Capybara