percy-client 1.15.0 → 2.0.0

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
- SHA1:
3
- metadata.gz: '059d2c2debca0b120960077ae094f60833105028'
4
- data.tar.gz: ac1f28ab489a811a14e5557a47d84e951ddf7c75
2
+ SHA256:
3
+ metadata.gz: e10f04f7f40f0eb144df84018041f83e0a1c527cacf70b5ac20982155f57b845
4
+ data.tar.gz: 3375ae5ec84774af2a45b135dc66d75d3301f2c1b21a1114051c2e338d25133d
5
5
  SHA512:
6
- metadata.gz: 704386465de40fc8c1dc024fd856022f2200ae4981a9879b39a5d67d59fd07a2ae793cfd03ec96c2b43a1f663f4f41da16b7a541bb1fecf14cff46cf7938febb
7
- data.tar.gz: e952bea0d6863372cfdfbe701bf248fdc1ff41310f49119872b711c8ded4a6e399eb259714aae64b0ecd9e041a07208038bd56a5db790c2ae3b95b6df92a8b48
6
+ metadata.gz: 48b8e48c3307aa0f712e105580c43b16cd2bd0a4a36fc1046bf7a66a1045c82a3dc743c6e0b8b89187d76c639b32858e4afa6099e30bde41014962e884b34a61
7
+ data.tar.gz: 7d9599369cde0f1885a6917c184479af587d9e522a5b58d0410cc06128184c74de5845682338a8df0566e19e97ccdb5df2d12ea9a28d49b0727ff8d624207d78
@@ -1,7 +1,7 @@
1
1
  module Percy
2
2
  class Client
3
3
  module Builds
4
- def create_build(repo, options = {})
4
+ def create_build(options = {})
5
5
  pull_request_number = options[:pull_request_number] ||
6
6
  Percy::Client::Environment.pull_request_number
7
7
  commit_data = options[:commit_data] || Percy::Client::Environment.commit
@@ -60,7 +60,8 @@ module Percy
60
60
  data['data'].merge!(relationships_data)
61
61
  end
62
62
 
63
- build_data = post("#{config.api_url}/repos/#{repo}/builds/", data)
63
+ build_data = post("#{config.api_url}/builds/", data)
64
+
64
65
  Percy.logger.debug { "Build #{build_data['data']['id']} created" }
65
66
 
66
67
  parallelism_msg = if parallel_total_shards
@@ -170,34 +170,6 @@ module Percy
170
170
  end
171
171
  class << self; private :_raw_branch_output; end
172
172
 
173
- def self.repo
174
- return ENV['PERCY_PROJECT'] if ENV['PERCY_PROJECT']
175
- return ENV['PERCY_REPO_SLUG'] if ENV['PERCY_REPO_SLUG'] # Deprecated.
176
-
177
- case current_ci
178
- when :travis
179
- ENV['TRAVIS_REPO_SLUG']
180
- when :circle
181
- "#{ENV['CIRCLE_PROJECT_USERNAME']}/#{ENV['CIRCLE_PROJECT_REPONAME']}"
182
- when :semaphore
183
- ENV['SEMAPHORE_REPO_SLUG']
184
- else
185
- origin_url = _get_origin_url.strip
186
- if origin_url == ''
187
- raise Percy::Client::Environment::RepoNotFoundError,
188
- 'No local git repository found. ' \
189
- 'You can manually set PERCY_PROJECT to fix this. See https://percy.io/docs'
190
- end
191
- match = origin_url.match(Regexp.new('[:/]([^/]+\/[^/]+?)(\.git)?\Z'))
192
- unless match
193
- raise Percy::Client::Environment::RepoNotFoundError,
194
- "Could not determine repository name from URL: #{origin_url.inspect}\n" \
195
- 'You can manually set PERCY_PROJECT to fix this. See https://percy.io/docs'
196
- end
197
- match[1]
198
- end
199
- end
200
-
201
173
  def self.pull_request_number
202
174
  return ENV['PERCY_PULL_REQUEST'] if ENV['PERCY_PULL_REQUEST']
203
175
 
@@ -1,5 +1,5 @@
1
1
  module Percy
2
2
  class Client
3
- VERSION = '1.15.0'.freeze
3
+ VERSION = '2.0.0'.freeze
4
4
  end
5
5
  end
@@ -1,20 +1,17 @@
1
1
  module Percy
2
2
  class Config
3
3
  # @!attribute [w] access_token
4
- # @return [String] Percy repo access token.
4
+ # @return [String] Percy project access token.
5
5
  # @!attribute api_url
6
6
  # @return [String] Base URL for API requests. Default: https://percy.io/api/v1/
7
7
  # @!attribute debug
8
8
  # @return [Boolean] Whether or not to enable debug logging.
9
- # @!attribute repo
10
- # @return [String] Git repo name.
11
9
  # @!attribute default_widths
12
10
  # @return [Array] List of default widths for snapshot rendering unless overridden.
13
11
 
14
12
  attr_writer :access_token
15
13
  attr_writer :api_url
16
14
  attr_writer :debug
17
- attr_writer :repo
18
15
  attr_writer :default_widths
19
16
 
20
17
  # List of configurable keys for {Percy::Client}
@@ -24,7 +21,6 @@ module Percy
24
21
  :access_token,
25
22
  :api_url,
26
23
  :debug,
27
- :repo,
28
24
  :default_widths,
29
25
  ]
30
26
  end
@@ -41,10 +37,6 @@ module Percy
41
37
  @debug ||= ENV['PERCY_DEBUG'] == '1'
42
38
  end
43
39
 
44
- def repo
45
- @repo ||= Percy::Client::Environment.repo
46
- end
47
-
48
40
  # List of default widths sent for every snapshot, unless overridden on a per-snapshot basis.
49
41
  def default_widths
50
42
  @default_widths ||= []
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,6 +58,6 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"30","type":"builds","attributes":{"build-number":30,"state":"pending","is-pull-request":true,"pull-request-number":123,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:38.388Z","updated-at":"2015-06-11T00:20:38.388Z"},"links":{"self":"/api/v1/builds/30"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/30/relationships/commit","related":"/api/v1/builds/30/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/30/relationships/repo","related":"/api/v1/builds/30/repo"}},"base-build":{"links":{"self":"/api/v1/builds/30/relationships/base-build","related":"/api/v1/builds/30/base-build"},"data":{"type":"builds","id":"29"}},"approved-by":{"links":{"self":"/api/v1/builds/30/relationships/approved-by","related":"/api/v1/builds/30/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/30/relationships/snapshots","related":"/api/v1/builds/30/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/30/relationships/comparisons","related":"/api/v1/builds/30/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/30/relationships/missing-resources","related":"/api/v1/builds/30/missing-resources"},"data":[{"type":"resources","id":"5909034bd2f101fdfdbc552fdddf5a53df463e05d49f4f93f9bb5bee93a49017"}]}},"meta":{"finalize-link":"/api/v1/builds/30/finalize","approve-link":"/api/v1/builds/30/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"29","type":"builds","attributes":{"build-number":29,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:38.000Z","updated-at":"2015-06-11T00:20:38.000Z"},"links":{"self":"/api/v1/builds/29"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/29/relationships/commit","related":"/api/v1/builds/29/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/29/relationships/repo","related":"/api/v1/builds/29/repo"}},"base-build":{"links":{"self":"/api/v1/builds/29/relationships/base-build","related":"/api/v1/builds/29/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/29/relationships/approved-by","related":"/api/v1/builds/29/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/29/relationships/snapshots","related":"/api/v1/builds/29/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/29/relationships/comparisons","related":"/api/v1/builds/29/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/29/relationships/missing-resources","related":"/api/v1/builds/29/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/29/finalize","approve-link":"/api/v1/builds/29/approve"}},{"id":"5909034bd2f101fdfdbc552fdddf5a53df463e05d49f4f93f9bb5bee93a49017","type":"resources","attributes":{},"links":{"self":"/api/v1/resources/5909034bd2f101fdfdbc552fdddf5a53df463e05d49f4f93f9bb5bee93a49017"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:38 GMT
63
63
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,6 +58,6 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"31","type":"builds","attributes":{"build-number":31,"state":"pending","is-pull-request":true,"pull-request-number":123,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:38.926Z","updated-at":"2015-06-11T00:20:38.926Z"},"links":{"self":"/api/v1/builds/31"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/31/relationships/commit","related":"/api/v1/builds/31/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/31/relationships/repo","related":"/api/v1/builds/31/repo"}},"base-build":{"links":{"self":"/api/v1/builds/31/relationships/base-build","related":"/api/v1/builds/31/base-build"},"data":{"type":"builds","id":"29"}},"approved-by":{"links":{"self":"/api/v1/builds/31/relationships/approved-by","related":"/api/v1/builds/31/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/31/relationships/snapshots","related":"/api/v1/builds/31/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/31/relationships/comparisons","related":"/api/v1/builds/31/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/31/relationships/missing-resources","related":"/api/v1/builds/31/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/31/finalize","approve-link":"/api/v1/builds/31/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"29","type":"builds","attributes":{"build-number":29,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:38.000Z","updated-at":"2015-06-11T00:20:38.000Z"},"links":{"self":"/api/v1/builds/29"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/29/relationships/commit","related":"/api/v1/builds/29/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/29/relationships/repo","related":"/api/v1/builds/29/repo"}},"base-build":{"links":{"self":"/api/v1/builds/29/relationships/base-build","related":"/api/v1/builds/29/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/29/relationships/approved-by","related":"/api/v1/builds/29/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/29/relationships/snapshots","related":"/api/v1/builds/29/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/29/relationships/comparisons","related":"/api/v1/builds/29/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/29/relationships/missing-resources","related":"/api/v1/builds/29/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/29/finalize","approve-link":"/api/v1/builds/29/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:39 GMT
63
63
  recorded_with: VCR 2.9.3
@@ -0,0 +1,61 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://localhost:3000/api/v1/builds/
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"data":{"type":"builds","attributes":{"branch":"map/update-to-token-only-build-endpoint","target-branch":null,"target-commit-sha":null,"commit-sha":"573b0e7995c8a8b7f77039f969cb15794e2e969d","commit-committed-at":"2018-08-08
9
+ 09:22:26 -0500","commit-author-name":"<COMMIT_AUTHOR_NAME>","commit-author-email":"<COMMIT_AUTHOR_EMAIL>","commit-committer-name":"<COMMIT_AUTHOR_NAME>","commit-committer-email":"<COMMIT_AUTHOR_EMAIL>","commit-message":"Manually
10
+ update cassettes to use projects endpoint instead of repos","pull-request-number":null,"parallel-nonce":null,"parallel-total-shards":null}}}'
11
+ headers:
12
+ User-Agent:
13
+ - Percy/v1 percy-client/1.15.0 (ruby/2.3.3p222; )
14
+ Content-Type:
15
+ - application/vnd.api+json
16
+ Authorization:
17
+ - Token token="<FILTERED_PERCY_TOKEN>"
18
+ response:
19
+ status:
20
+ code: 201
21
+ message: Created
22
+ headers:
23
+ Content-Type:
24
+ - application/json; charset=utf-8
25
+ Connection:
26
+ - keep-alive
27
+ Status:
28
+ - 201 Created
29
+ Cache-Control:
30
+ - no-cache, no-store, max-age=0, must-revalidate
31
+ Access-Control-Allow-Origin:
32
+ - "*"
33
+ X-Xss-Protection:
34
+ - 1; mode=block
35
+ X-Request-Id:
36
+ - 42bb4220-344f-40ec-a7f4-2a611cccca9b
37
+ Access-Control-Allow-Headers:
38
+ - Authorization, Content-Type
39
+ Access-Control-Allow-Methods:
40
+ - GET, POST, PUT, PATCH, DELETE, OPTIONS
41
+ X-Runtime:
42
+ - '0.286637'
43
+ X-Frame-Options:
44
+ - SAMEORIGIN
45
+ X-Content-Type-Options:
46
+ - nosniff
47
+ Expires:
48
+ - Thu, 01 Jan 1970 00:00:00 GMT
49
+ Date:
50
+ - Wed, 08 Aug 2018 19:09:33 GMT
51
+ Server:
52
+ - nginx/1.14.0 + Phusion Passenger 5.3.4
53
+ body:
54
+ encoding: ASCII-8BIT
55
+ string: '{"data":{"type":"builds","id":"17","attributes":{"branch":"map/update-to-token-only-build-endpoint","build-number":8,"web-url":"http://dev.percy.local:4200/fotinakis/percy-examples/builds/17","state":"pending","review-state":null,"review-state-reason":null,"is-pull-request":false,"pull-request-number":null,"pull-request-title":null,"pull-request-html-url":null,"user-agent":"Percy/v1
56
+ percy-client/1.15.0 (ruby/2.3.3p222; )","total-snapshots":null,"total-snapshots-unreviewed":null,"total-comparisons":null,"total-comparisons-finished":null,"total-comparisons-diff":null,"failure-reason":null,"failure-details":null,"parallel-nonce":null,"parallel-total-shards":null,"finished-at":null,"approved-at":null,"created-at":"2018-08-08T19:09:33.000Z","updated-at":"2018-08-08T19:09:33.000Z"},"links":{"self":"/api/v1/builds/17"},"relationships":{"project":{"links":{"self":"/api/v1/builds/17/relationships/project","related":"/api/v1/builds/17/project"},"data":{"type":"projects","id":"9"}},"commit":{"links":{"self":"/api/v1/builds/17/relationships/commit","related":"/api/v1/builds/17/commit"},"data":{"type":"commits","id":"5"}},"repo":{"links":{"self":"/api/v1/builds/17/relationships/repo","related":"/api/v1/builds/17/repo"},"data":null},"base-build":{"links":{"self":"/api/v1/builds/17/relationships/base-build","related":"/api/v1/builds/17/base-build"},"data":null},"approved-by":{"links":{"self":"/api/v1/builds/17/relationships/approved-by","related":"/api/v1/builds/17/approved-by"},"data":null},"snapshots":{"links":{"self":"/api/v1/builds/17/relationships/snapshots","related":"/api/v1/builds/17/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/17/relationships/comparisons","related":"/api/v1/builds/17/comparisons"}},"browsers":{"links":{"self":"/api/v1/builds/17/relationships/browsers","related":"/api/v1/builds/17/browsers"},"data":[{"type":"browsers","id":"5"},{"type":"browsers","id":"7"}]},"missing-resources":{"links":{"self":"/api/v1/builds/17/relationships/missing-resources","related":"/api/v1/builds/17/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/17/finalize","approve-link":"/api/v1/builds/17/approve"}},"included":[{"type":"projects","id":"9","attributes":{"name":"percy-examples","slug":"percy-examples","full-slug":"fotinakis/percy-examples","is-enabled":true,"diff-base":"automatic","auto-approve-branch-filter":"master","created-at":"2018-08-07T21:55:38.000Z","updated-at":"2018-08-07T21:55:38.000Z"},"links":{"self":"/api/v1/projects/fotinakis/percy-examples"},"relationships":{"organization":{"links":{"self":"/api/v1/projects/fotinakis/percy-examples/relationships/organization","related":"/api/v1/projects/fotinakis/percy-examples/organization"}},"repo":{"links":{"self":"/api/v1/projects/fotinakis/percy-examples/relationships/repo","related":"/api/v1/projects/fotinakis/percy-examples/repo"}},"builds":{"links":{"self":"/api/v1/projects/fotinakis/percy-examples/relationships/builds","related":"/api/v1/projects/fotinakis/percy-examples/builds"}},"tokens":{"links":{"self":"/api/v1/projects/fotinakis/percy-examples/relationships/tokens","related":"/api/v1/projects/fotinakis/percy-examples/tokens"}},"browser-targets":{},"project-browser-targets":{}}},{"type":"commits","id":"5","attributes":{"sha":"573b0e7995c8a8b7f77039f969cb15794e2e969d","message":"Manually
57
+ update cassettes to use projects endpoint instead of repos","committed-at":"2018-08-08
58
+ 09:22:26 -0500","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2018-08-08T18:54:38.000Z","updated-at":"2018-08-08T18:54:38.000Z"},"links":{"self":"/api/v1/commits/5"}},{"type":"browsers","id":"5","attributes":{"version":"52.5.3esr","created-at":"2018-06-01T01:31:13.000Z","updated-at":"2018-06-01T01:31:13.000Z"},"links":{"self":"/api/v1/browsers/5"},"relationships":{"operating-system":{},"browser-family":{"data":{"type":"browser-families","id":"1"}}}},{"type":"browsers","id":"7","attributes":{"version":"67.0.3396.99","created-at":"2018-07-12T17:17:04.000Z","updated-at":"2018-07-12T17:17:04.000Z"},"links":{"self":"/api/v1/browsers/7"},"relationships":{"operating-system":{},"browser-family":{"data":{"type":"browser-families","id":"2"}}}},{"type":"browser-families","id":"1","attributes":{"name":"Firefox","slug":"firefox"}},{"type":"browser-families","id":"2","attributes":{"name":"Chrome","slug":"chrome"}}]}'
59
+ http_version:
60
+ recorded_at: Wed, 08 Aug 2018 19:09:33 GMT
61
+ recorded_with: VCR 3.0.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"29","type":"builds","attributes":{"build-number":29,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:38.233Z","updated-at":"2015-06-11T00:20:38.233Z"},"links":{"self":"/api/v1/builds/29"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/29/relationships/commit","related":"/api/v1/builds/29/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/29/relationships/repo","related":"/api/v1/builds/29/repo"}},"base-build":{"links":{"self":"/api/v1/builds/29/relationships/base-build","related":"/api/v1/builds/29/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/29/relationships/approved-by","related":"/api/v1/builds/29/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/29/relationships/snapshots","related":"/api/v1/builds/29/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/29/relationships/comparisons","related":"/api/v1/builds/29/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/29/relationships/missing-resources","related":"/api/v1/builds/29/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/29/finalize","approve-link":"/api/v1/builds/29/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:38 GMT
63
63
  - request:
64
64
  method: post
@@ -115,6 +115,6 @@ http_interactions:
115
115
  body:
116
116
  encoding: UTF-8
117
117
  string: '{"success":true}'
118
- http_version:
118
+ http_version:
119
119
  recorded_at: Thu, 11 Jun 2015 00:20:38 GMT
120
120
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"25","type":"builds","attributes":{"build-number":25,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:36.192Z","updated-at":"2015-06-11T00:20:36.192Z"},"links":{"self":"/api/v1/builds/25"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/25/relationships/commit","related":"/api/v1/builds/25/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/25/relationships/repo","related":"/api/v1/builds/25/repo"}},"base-build":{"links":{"self":"/api/v1/builds/25/relationships/base-build","related":"/api/v1/builds/25/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/25/relationships/approved-by","related":"/api/v1/builds/25/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/25/relationships/snapshots","related":"/api/v1/builds/25/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/25/relationships/comparisons","related":"/api/v1/builds/25/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/25/relationships/missing-resources","related":"/api/v1/builds/25/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/25/finalize","approve-link":"/api/v1/builds/25/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:36 GMT
63
63
  - request:
64
64
  method: post
@@ -115,7 +115,7 @@ http_interactions:
115
115
  body:
116
116
  encoding: UTF-8
117
117
  string: '{"data":{"id":"1108","type":"snapshots","attributes":{"name":"homepage","created-at":"2015-06-11T00:20:36.248Z","updated-at":"2015-06-11T00:20:36.248Z","finished-processing-at":null},"links":{"self":"/api/v1/snapshots/1108"},"relationships":{"build":{"links":{"self":"/api/v1/snapshots/1108/relationships/build","related":"/api/v1/snapshots/1108/build"}},"screenshots":{"links":{"self":"/api/v1/snapshots/1108/relationships/screenshots","related":"/api/v1/snapshots/1108/screenshots"}},"missing-resources":{"links":{"self":"/api/v1/snapshots/1108/relationships/missing-resources","related":"/api/v1/snapshots/1108/missing-resources"},"data":[{"type":"resources","id":"0ae24db123b4b8b506d27ccd61fb20de2d29e71ca6c2737dee6078db0f716602"}]}}},"included":[{"id":"0ae24db123b4b8b506d27ccd61fb20de2d29e71ca6c2737dee6078db0f716602","type":"resources","attributes":{},"links":{"self":"/api/v1/resources/0ae24db123b4b8b506d27ccd61fb20de2d29e71ca6c2737dee6078db0f716602"}}]}'
118
- http_version:
118
+ http_version:
119
119
  recorded_at: Thu, 11 Jun 2015 00:20:36 GMT
120
120
  - request:
121
121
  method: post
@@ -172,7 +172,7 @@ http_interactions:
172
172
  body:
173
173
  encoding: UTF-8
174
174
  string: '{"success":true}'
175
- http_version:
175
+ http_version:
176
176
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
177
177
  - request:
178
178
  method: post
@@ -231,6 +231,6 @@ http_interactions:
231
231
  string: '{"errors":[{"status":"conflict","detail":"Upload failed, resource with
232
232
  SHA-256 ''0ae24db123b4b8b506d27ccd61fb20de2d29e71ca6c2737dee6078db0f716602''
233
233
  already exists."}]}'
234
- http_version:
234
+ http_version:
235
235
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
236
236
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"28","type":"builds","attributes":{"build-number":28,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:37.863Z","updated-at":"2015-06-11T00:20:37.863Z"},"links":{"self":"/api/v1/builds/28"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/28/relationships/commit","related":"/api/v1/builds/28/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/28/relationships/repo","related":"/api/v1/builds/28/repo"}},"base-build":{"links":{"self":"/api/v1/builds/28/relationships/base-build","related":"/api/v1/builds/28/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/28/relationships/approved-by","related":"/api/v1/builds/28/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/28/relationships/snapshots","related":"/api/v1/builds/28/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/28/relationships/comparisons","related":"/api/v1/builds/28/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/28/relationships/missing-resources","related":"/api/v1/builds/28/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/28/finalize","approve-link":"/api/v1/builds/28/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
63
63
  - request:
64
64
  method: post
@@ -115,6 +115,6 @@ http_interactions:
115
115
  body:
116
116
  encoding: UTF-8
117
117
  string: '{"data":{"id":"1110","type":"snapshots","attributes":{"name":"homepage","created-at":"2015-06-11T00:20:38.085Z","updated-at":"2015-06-11T00:20:38.085Z","finished-processing-at":null},"links":{"self":"/api/v1/snapshots/1110"},"relationships":{"build":{"links":{"self":"/api/v1/snapshots/1110/relationships/build","related":"/api/v1/snapshots/1110/build"}},"screenshots":{"links":{"self":"/api/v1/snapshots/1110/relationships/screenshots","related":"/api/v1/snapshots/1110/screenshots"}},"missing-resources":{"links":{"self":"/api/v1/snapshots/1110/relationships/missing-resources","related":"/api/v1/snapshots/1110/missing-resources"},"data":[{"type":"resources","id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}]}}},"included":[{"id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a","type":"resources","attributes":{},"links":{"self":"/api/v1/resources/8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}}]}'
118
- http_version:
118
+ http_version:
119
119
  recorded_at: Thu, 11 Jun 2015 00:20:38 GMT
120
120
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"27","type":"builds","attributes":{"build-number":27,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:37.746Z","updated-at":"2015-06-11T00:20:37.746Z"},"links":{"self":"/api/v1/builds/27"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/27/relationships/commit","related":"/api/v1/builds/27/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/27/relationships/repo","related":"/api/v1/builds/27/repo"}},"base-build":{"links":{"self":"/api/v1/builds/27/relationships/base-build","related":"/api/v1/builds/27/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/27/relationships/approved-by","related":"/api/v1/builds/27/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/27/relationships/snapshots","related":"/api/v1/builds/27/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/27/relationships/comparisons","related":"/api/v1/builds/27/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/27/relationships/missing-resources","related":"/api/v1/builds/27/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/27/finalize","approve-link":"/api/v1/builds/27/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
63
63
  - request:
64
64
  method: post
@@ -117,6 +117,6 @@ http_interactions:
117
117
  string: '{"errors":[{"status":"bad_request","detail":"Exactly one resource with
118
118
  ''is-root'': true must be present in the ''resources'' array. Found 0 root
119
119
  resources in 0 total resources."}]}'
120
- http_version:
120
+ http_version:
121
121
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
122
122
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"28","type":"builds","attributes":{"build-number":28,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:37.863Z","updated-at":"2015-06-11T00:20:37.863Z"},"links":{"self":"/api/v1/builds/28"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/28/relationships/commit","related":"/api/v1/builds/28/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/28/relationships/repo","related":"/api/v1/builds/28/repo"}},"base-build":{"links":{"self":"/api/v1/builds/28/relationships/base-build","related":"/api/v1/builds/28/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/28/relationships/approved-by","related":"/api/v1/builds/28/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/28/relationships/snapshots","related":"/api/v1/builds/28/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/28/relationships/comparisons","related":"/api/v1/builds/28/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/28/relationships/missing-resources","related":"/api/v1/builds/28/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/28/finalize","approve-link":"/api/v1/builds/28/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
63
63
  - request:
64
64
  method: post
@@ -115,6 +115,6 @@ http_interactions:
115
115
  body:
116
116
  encoding: UTF-8
117
117
  string: '{"data":{"id":"1110","type":"snapshots","attributes":{"name":"homepage","created-at":"2015-06-11T00:20:38.085Z","updated-at":"2015-06-11T00:20:38.085Z","finished-processing-at":null},"links":{"self":"/api/v1/snapshots/1110"},"relationships":{"build":{"links":{"self":"/api/v1/snapshots/1110/relationships/build","related":"/api/v1/snapshots/1110/build"}},"screenshots":{"links":{"self":"/api/v1/snapshots/1110/relationships/screenshots","related":"/api/v1/snapshots/1110/screenshots"}},"missing-resources":{"links":{"self":"/api/v1/snapshots/1110/relationships/missing-resources","related":"/api/v1/snapshots/1110/missing-resources"},"data":[{"type":"resources","id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}]}}},"included":[{"id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a","type":"resources","attributes":{},"links":{"self":"/api/v1/resources/8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}}]}'
118
- http_version:
118
+ http_version:
119
119
  recorded_at: Thu, 11 Jun 2015 00:20:38 GMT
120
120
  recorded_with: VCR 2.9.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: post
5
- uri: http://localhost:3000/api/v1/repos/fotinakis/percy-examples/builds/
5
+ uri: http://localhost:3000/api/v1/builds/
6
6
  body:
7
7
  encoding: UTF-8
8
8
  string: '{"data":{"type":"builds","attributes":{"commit-sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","commit-branch":"master","commit-committed-at":"2015-06-09
@@ -58,7 +58,7 @@ http_interactions:
58
58
  encoding: UTF-8
59
59
  string: '{"data":{"id":"26","type":"builds","attributes":{"build-number":26,"state":"pending","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:20:37.546Z","updated-at":"2015-06-11T00:20:37.546Z"},"links":{"self":"/api/v1/builds/26"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/26/relationships/commit","related":"/api/v1/builds/26/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/26/relationships/repo","related":"/api/v1/builds/26/repo"}},"base-build":{"links":{"self":"/api/v1/builds/26/relationships/base-build","related":"/api/v1/builds/26/base-build"},"data":{"type":"builds","id":"22"}},"approved-by":{"links":{"self":"/api/v1/builds/26/relationships/approved-by","related":"/api/v1/builds/26/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/26/relationships/snapshots","related":"/api/v1/builds/26/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/26/relationships/comparisons","related":"/api/v1/builds/26/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/26/relationships/missing-resources","related":"/api/v1/builds/26/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/26/finalize","approve-link":"/api/v1/builds/26/approve"}},"included":[{"id":"2","type":"commits","attributes":{"sha":"fc4d2c2e6b55d995a005dba2d071e2f2fca5e04b","branch":"master","message":"Fix
60
60
  test environment issue.","committed-at":"2015-06-09 23:22:31 -0700","author-name":"<COMMIT_AUTHOR_NAME>","committer-name":"<COMMIT_AUTHOR_NAME>","created-at":"2015-06-11T00:15:24.000Z","updated-at":"2015-06-11T00:15:24.000Z"},"links":{"self":"/api/v1/commits/2"}},{"id":"22","type":"builds","attributes":{"build-number":22,"state":"finished","is-pull-request":false,"pull-request-number":0,"pull-request-title":null,"approved-at":null,"created-at":"2015-06-11T00:17:46.000Z","updated-at":"2015-06-11T00:17:46.000Z"},"links":{"self":"/api/v1/builds/22"},"relationships":{"commit":{"links":{"self":"/api/v1/builds/22/relationships/commit","related":"/api/v1/builds/22/commit"},"data":{"type":"commits","id":"2"}},"repo":{"links":{"self":"/api/v1/builds/22/relationships/repo","related":"/api/v1/builds/22/repo"}},"base-build":{"links":{"self":"/api/v1/builds/22/relationships/base-build","related":"/api/v1/builds/22/base-build"}},"approved-by":{"links":{"self":"/api/v1/builds/22/relationships/approved-by","related":"/api/v1/builds/22/approved-by"}},"snapshots":{"links":{"self":"/api/v1/builds/22/relationships/snapshots","related":"/api/v1/builds/22/snapshots"}},"comparisons":{"links":{"self":"/api/v1/builds/22/relationships/comparisons","related":"/api/v1/builds/22/comparisons"}},"missing-resources":{"links":{"self":"/api/v1/builds/22/relationships/missing-resources","related":"/api/v1/builds/22/missing-resources"}}},"meta":{"finalize-link":"/api/v1/builds/22/finalize","approve-link":"/api/v1/builds/22/approve"}}]}'
61
- http_version:
61
+ http_version:
62
62
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
63
63
  - request:
64
64
  method: post
@@ -115,7 +115,7 @@ http_interactions:
115
115
  body:
116
116
  encoding: UTF-8
117
117
  string: '{"data":{"id":"1109","type":"snapshots","attributes":{"name":"homepage","created-at":"2015-06-11T00:20:37.582Z","updated-at":"2015-06-11T00:20:37.582Z","finished-processing-at":null},"links":{"self":"/api/v1/snapshots/1109"},"relationships":{"build":{"links":{"self":"/api/v1/snapshots/1109/relationships/build","related":"/api/v1/snapshots/1109/build"}},"screenshots":{"links":{"self":"/api/v1/snapshots/1109/relationships/screenshots","related":"/api/v1/snapshots/1109/screenshots"}},"missing-resources":{"links":{"self":"/api/v1/snapshots/1109/relationships/missing-resources","related":"/api/v1/snapshots/1109/missing-resources"},"data":[{"type":"resources","id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}]}}},"included":[{"id":"8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a","type":"resources","attributes":{},"links":{"self":"/api/v1/resources/8d68af40ce7ee4591a7df49d1a40db8bf0b6535a37c896eda504f963c622535a"}}]}'
118
- http_version:
118
+ http_version:
119
119
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
120
120
  - request:
121
121
  method: post
@@ -172,6 +172,6 @@ http_interactions:
172
172
  body:
173
173
  encoding: UTF-8
174
174
  string: '{"success":true}'
175
- http_version:
175
+ http_version:
176
176
  recorded_at: Thu, 11 Jun 2015 00:20:37 GMT
177
177
  recorded_with: VCR 2.9.3
@@ -8,7 +8,7 @@ RSpec.describe Percy::Client::Builds, :vcr do
8
8
  expect_any_instance_of(Percy::Client).to \
9
9
  receive(:post)
10
10
  .with(
11
- /\/api\/v1\/repos\/fotinakis\/percy-examples\/builds\//,
11
+ /\/api\/v1\/builds\//,
12
12
  'data' => {
13
13
  'type' => 'builds',
14
14
  'attributes' => {
@@ -29,7 +29,7 @@ RSpec.describe Percy::Client::Builds, :vcr do
29
29
  },
30
30
  ).and_call_original
31
31
 
32
- build = Percy.create_build('fotinakis/percy-examples')
32
+ build = Percy.create_build()
33
33
  expect(build).to be
34
34
  expect(build['data']).to be
35
35
  expect(build['data']['id']).to be
@@ -45,7 +45,7 @@ RSpec.describe Percy::Client::Builds, :vcr do
45
45
  resources = []
46
46
  resources << Percy::Client::Resource.new('/css/test.css', sha: sha)
47
47
 
48
- build = Percy.create_build('fotinakis/percy-examples', resources: resources)
48
+ build = Percy.create_build(resources: resources)
49
49
  expect(build).to be
50
50
  expect(build['data']).to be
51
51
  expect(build['data']['id']).to be
@@ -82,7 +82,7 @@ RSpec.describe Percy::Client::Builds, :vcr do
82
82
  expect_any_instance_of(Percy::Client).to \
83
83
  receive(:post)
84
84
  .with(
85
- /\/api\/v1\/repos\/fotinakis\/percy-examples\/builds\//,
85
+ /\/api\/v1\/builds\//,
86
86
  'data' => {
87
87
  'type' => 'builds',
88
88
  'attributes' => {
@@ -103,14 +103,13 @@ RSpec.describe Percy::Client::Builds, :vcr do
103
103
  },
104
104
  )
105
105
 
106
- Percy.create_build('fotinakis/percy-examples')
106
+ Percy.create_build()
107
107
  end
108
108
  end
109
109
 
110
110
  context 'when in a parallel test environment' do
111
111
  it 'passes through parallelism variables' do
112
112
  build = Percy.create_build(
113
- 'fotinakis/percy-examples',
114
113
  parallel_nonce: 'nonce',
115
114
  parallel_total_shards: 2,
116
115
  )
@@ -122,7 +121,7 @@ RSpec.describe Percy::Client::Builds, :vcr do
122
121
 
123
122
  describe '#finalize_build' do
124
123
  it 'finalizes a build' do
125
- build = Percy.create_build('fotinakis/percy-examples')
124
+ build = Percy.create_build()
126
125
  result = Percy.finalize_build(build['data']['id'])
127
126
  expect(result).to eq('success' => true)
128
127
  end
@@ -6,8 +6,6 @@ RSpec.describe Percy::Client::Environment do
6
6
  ENV['PERCY_TARGET_COMMIT'] = nil
7
7
  ENV['PERCY_TARGET_BRANCH'] = nil
8
8
  ENV['PERCY_PULL_REQUEST'] = nil
9
- ENV['PERCY_PROJECT'] = nil
10
- ENV['PERCY_REPO_SLUG'] = nil # Deprecated.
11
9
  ENV['PERCY_PARALLEL_NONCE'] = nil
12
10
  ENV['PERCY_PARALLEL_TOTAL'] = nil
13
11
 
@@ -18,7 +16,6 @@ RSpec.describe Percy::Client::Environment do
18
16
  ENV['TRAVIS_BRANCH'] = nil
19
17
  ENV['TRAVIS_PULL_REQUEST'] = nil
20
18
  ENV['TRAVIS_PULL_REQUEST_BRANCH'] = nil
21
- ENV['TRAVIS_REPO_SLUG'] = nil
22
19
  ENV['CI_NODE_TOTAL'] = nil
23
20
 
24
21
  # Unset Jenkins vars.
@@ -32,8 +29,6 @@ RSpec.describe Percy::Client::Environment do
32
29
  ENV['CIRCLECI'] = nil
33
30
  ENV['CIRCLE_SHA1'] = nil
34
31
  ENV['CIRCLE_BRANCH'] = nil
35
- ENV['CIRCLE_PROJECT_USERNAME'] = nil
36
- ENV['CIRCLE_PROJECT_REPONAME'] = nil
37
32
  ENV['CIRCLE_BUILD_NUM'] = nil
38
33
  ENV['CI_PULL_REQUESTS'] = nil
39
34
 
@@ -57,7 +52,6 @@ RSpec.describe Percy::Client::Environment do
57
52
  ENV['SEMAPHORE'] = nil
58
53
  ENV['REVISION'] = nil
59
54
  ENV['BRANCH_NAME'] = nil
60
- ENV['SEMAPHORE_REPO_SLUG'] = nil
61
55
  ENV['SEMAPHORE_BRANCH_ID'] = nil
62
56
  ENV['SEMAPHORE_BUILD_NUMBER'] = nil
63
57
  ENV['SEMAPHORE_CURRENT_THREAD'] = nil
@@ -85,7 +79,6 @@ RSpec.describe Percy::Client::Environment do
85
79
  'TRAVIS_BRANCH' => ENV['TRAVIS_BRANCH'],
86
80
  'TRAVIS_PULL_REQUEST' => ENV['TRAVIS_PULL_REQUEST'],
87
81
  'TRAVIS_PULL_REQUEST_BRANCH' => ENV['TRAVIS_PULL_REQUEST_BRANCH'],
88
- 'TRAVIS_REPO_SLUG' => ENV['TRAVIS_REPO_SLUG'],
89
82
  }
90
83
  clear_env_vars
91
84
  end
@@ -98,7 +91,6 @@ RSpec.describe Percy::Client::Environment do
98
91
  ENV['TRAVIS_BRANCH'] = @original_env['TRAVIS_BRANCH']
99
92
  ENV['TRAVIS_PULL_REQUEST'] = @original_env['TRAVIS_PULL_REQUEST']
100
93
  ENV['TRAVIS_PULL_REQUEST_BRANCH'] = @original_env['TRAVIS_PULL_REQUEST_BRANCH']
101
- ENV['TRAVIS_REPO_SLUG'] = @original_env['TRAVIS_REPO_SLUG']
102
94
  end
103
95
 
104
96
  context 'with no known CI environment' do
@@ -170,57 +162,6 @@ RSpec.describe Percy::Client::Environment do
170
162
  end
171
163
  end
172
164
 
173
- describe '#repo' do
174
- it 'returns the current local repo name' do
175
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client')
176
- end
177
-
178
- it 'can be overridden with PERCY_PROJECT' do
179
- ENV['PERCY_PROJECT'] = 'percy/slug'
180
- expect(Percy::Client::Environment.repo).to eq('percy/slug')
181
- end
182
-
183
- it 'can be overridden with PERCY_REPO_SLUG (deprecated)' do
184
- ENV['PERCY_REPO_SLUG'] = 'percy/slug'
185
- expect(Percy::Client::Environment.repo).to eq('percy/slug')
186
- end
187
-
188
- it 'handles git ssh urls' do
189
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
190
- .once.and_return('git@github.com:org-name/repo-name.git')
191
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name')
192
-
193
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
194
- .once.and_return('git@github.com:org-name/repo-name.org.git')
195
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name.org')
196
-
197
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
198
- .once.and_return('git@custom-local-hostname:org-name/repo-name.org')
199
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name.org')
200
- end
201
-
202
- it 'handles git https urls' do
203
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
204
- .once.and_return('https://github.com/org-name/repo-name.git')
205
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name')
206
-
207
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
208
- .once.and_return('https://github.com/org-name/repo-name.org.git')
209
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name.org')
210
-
211
- expect(Percy::Client::Environment).to receive(:_get_origin_url)
212
- .once.and_return("https://github.com/org-name/repo-name.org\n")
213
- expect(Percy::Client::Environment.repo).to eq('org-name/repo-name.org')
214
- end
215
-
216
- it 'errors if unable to parse local repo name' do
217
- expect(Percy::Client::Environment).to receive(:_get_origin_url).once.and_return('foo')
218
- expect { Percy::Client::Environment.repo }.to raise_error(
219
- Percy::Client::Environment::RepoNotFoundError,
220
- )
221
- end
222
- end
223
-
224
165
  describe '#parallel_nonce' do
225
166
  it 'returns nil' do
226
167
  expect(Percy::Client::Environment.parallel_nonce).to be_nil
@@ -267,7 +208,6 @@ RSpec.describe Percy::Client::Environment do
267
208
  expect(Percy::Client::Environment.branch).to eq('jenkins-source-branch')
268
209
  expect(Percy::Client::Environment._commit_sha).to eq('jenkins-actual-commit')
269
210
  expect(Percy::Client::Environment.pull_request_number).to eq('256')
270
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client')
271
211
  expect(Percy::Client::Environment.parallel_nonce).to eq('111')
272
212
  expect(Percy::Client::Environment.parallel_total_shards).to eq(nil)
273
213
  end
@@ -279,7 +219,6 @@ RSpec.describe Percy::Client::Environment do
279
219
  ENV['TRAVIS_BUILD_NUMBER'] = 'build-number'
280
220
  ENV['TRAVIS_PULL_REQUEST'] = 'false'
281
221
  ENV['TRAVIS_PULL_REQUEST_BRANCH'] = ''
282
- ENV['TRAVIS_REPO_SLUG'] = 'travis/repo-slug'
283
222
  ENV['TRAVIS_COMMIT'] = 'travis-commit-sha'
284
223
  ENV['TRAVIS_BRANCH'] = 'travis-branch'
285
224
  ENV['CI_NODE_TOTAL'] = ''
@@ -291,7 +230,6 @@ RSpec.describe Percy::Client::Environment do
291
230
  expect(Percy::Client::Environment.branch).to eq('travis-branch')
292
231
  expect(Percy::Client::Environment._commit_sha).to eq('travis-commit-sha')
293
232
  expect(Percy::Client::Environment.pull_request_number).to be_nil
294
- expect(Percy::Client::Environment.repo).to eq('travis/repo-slug')
295
233
  expect(Percy::Client::Environment.parallel_nonce).to eq('build-number')
296
234
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
297
235
  end
@@ -326,8 +264,6 @@ RSpec.describe Percy::Client::Environment do
326
264
  ENV['CIRCLECI'] = 'true'
327
265
  ENV['CIRCLE_BRANCH'] = 'circle-branch'
328
266
  ENV['CIRCLE_SHA1'] = 'circle-commit-sha'
329
- ENV['CIRCLE_PROJECT_USERNAME'] = 'circle'
330
- ENV['CIRCLE_PROJECT_REPONAME'] = 'repo-name'
331
267
  ENV['CIRCLE_BUILD_NUM'] = 'build-number'
332
268
  ENV['CIRCLE_NODE_TOTAL'] = ''
333
269
  ENV['CI_PULL_REQUESTS'] = 'https://github.com/owner/repo-name/pull/123'
@@ -339,7 +275,6 @@ RSpec.describe Percy::Client::Environment do
339
275
  expect(Percy::Client::Environment.branch).to eq('circle-branch')
340
276
  expect(Percy::Client::Environment._commit_sha).to eq('circle-commit-sha')
341
277
  expect(Percy::Client::Environment.pull_request_number).to eq('123')
342
- expect(Percy::Client::Environment.repo).to eq('circle/repo-name')
343
278
  expect(Percy::Client::Environment.parallel_nonce).to eq('build-number')
344
279
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
345
280
  end
@@ -372,7 +307,6 @@ RSpec.describe Percy::Client::Environment do
372
307
  expect(Percy::Client::Environment.branch).to eq('codeship-branch')
373
308
  expect(Percy::Client::Environment._commit_sha).to eq('codeship-commit-sha')
374
309
  expect(Percy::Client::Environment.pull_request_number).to be_nil
375
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client')
376
310
  expect(Percy::Client::Environment.parallel_nonce).to eq('codeship-build-number')
377
311
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
378
312
  end
@@ -403,7 +337,6 @@ RSpec.describe Percy::Client::Environment do
403
337
  expect(Percy::Client::Environment.branch).to eq('drone-branch')
404
338
  expect(Percy::Client::Environment._commit_sha).to eq('drone-commit-sha')
405
339
  expect(Percy::Client::Environment.pull_request_number).to eq('123')
406
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client')
407
340
  end
408
341
  end
409
342
 
@@ -412,7 +345,6 @@ RSpec.describe Percy::Client::Environment do
412
345
  ENV['SEMAPHORE'] = 'true'
413
346
  ENV['BRANCH_NAME'] = 'semaphore-branch'
414
347
  ENV['REVISION'] = 'semaphore-commit-sha'
415
- ENV['SEMAPHORE_REPO_SLUG'] = 'repo-owner/repo-name'
416
348
  ENV['SEMAPHORE_BRANCH_ID'] = 'semaphore-branch-id'
417
349
  ENV['SEMAPHORE_BUILD_NUMBER'] = 'semaphore-build-number'
418
350
  ENV['SEMAPHORE_THREAD_COUNT'] = ''
@@ -425,7 +357,6 @@ RSpec.describe Percy::Client::Environment do
425
357
  expect(Percy::Client::Environment.branch).to eq('semaphore-branch')
426
358
  expect(Percy::Client::Environment._commit_sha).to eq('semaphore-commit-sha')
427
359
  expect(Percy::Client::Environment.pull_request_number).to eq('123')
428
- expect(Percy::Client::Environment.repo).to eq('repo-owner/repo-name')
429
360
  expected_nonce = 'semaphore-branch-id/semaphore-build-number'
430
361
  expect(Percy::Client::Environment.parallel_nonce).to eq(expected_nonce)
431
362
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
@@ -460,7 +391,6 @@ RSpec.describe Percy::Client::Environment do
460
391
  expect(Percy::Client::Environment.branch).to eq('buildkite-branch')
461
392
  expect(Percy::Client::Environment._commit_sha).to eq('buildkite-commit-sha')
462
393
  expect(Percy::Client::Environment.pull_request_number).to be_nil
463
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client') # From git, not env.
464
394
  expect(Percy::Client::Environment.parallel_nonce).to eq('buildkite-build-id')
465
395
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
466
396
  end
@@ -511,8 +441,6 @@ RSpec.describe Percy::Client::Environment do
511
441
  expect(Percy::Client::Environment.pull_request_number).to be_nil
512
442
  expect(Percy::Client::Environment.parallel_nonce).to eq('gitlab-build-id')
513
443
  expect(Percy::Client::Environment.parallel_total_shards).to be_nil
514
- # TODO: repo is deprecated, remove this:
515
- expect(Percy::Client::Environment.repo).to eq('percy/percy-client') # From git, not env.
516
444
  end
517
445
  end
518
446
 
@@ -7,7 +7,7 @@ RSpec.describe Percy::Client::Resources, :vcr do
7
7
 
8
8
  describe '#upload_resource' do
9
9
  it 'returns true with success' do
10
- build = Percy.create_build('fotinakis/percy-examples')
10
+ build = Percy.create_build()
11
11
  resources = [Percy::Client::Resource.new('/foo/test.html', sha: sha, is_root: true)]
12
12
  Percy.create_snapshot(build['data']['id'], resources, name: 'homepage')
13
13
 
@@ -4,7 +4,7 @@ RSpec.describe Percy::Client::Snapshots, :vcr do
4
4
 
5
5
  describe '#create_snapshot' do
6
6
  it 'creates a snapshot' do
7
- build = Percy.create_build('fotinakis/percy-examples')
7
+ build = Percy.create_build()
8
8
  resources = []
9
9
  resources << Percy::Client::Resource.new('/foo/test.html', sha: sha, is_root: true)
10
10
  resources << Percy::Client::Resource.new('/css/test.css', sha: sha)
@@ -64,7 +64,7 @@ RSpec.describe Percy::Client::Snapshots, :vcr do
64
64
  expect(snapshot['data']['relationships']['missing-resources']).to be
65
65
  end
66
66
  it 'passes through certain arguments' do
67
- build = Percy.create_build('fotinakis/percy-examples')
67
+ build = Percy.create_build()
68
68
  resources = []
69
69
  resources << Percy::Client::Resource.new('/foo/test.html', sha: sha, is_root: true)
70
70
  resources << Percy::Client::Resource.new('/css/test.css', sha: sha)
@@ -125,7 +125,7 @@ RSpec.describe Percy::Client::Snapshots, :vcr do
125
125
  expect(snapshot['data']['relationships']['missing-resources']).to be
126
126
  end
127
127
  it 'fails if no resources are given' do
128
- build = Percy.create_build('fotinakis/percy-examples')
128
+ build = Percy.create_build()
129
129
  expect do
130
130
  Percy.create_snapshot(build['data']['id'], [])
131
131
  end.to raise_error(Percy::Client::HttpError)
@@ -133,7 +133,7 @@ RSpec.describe Percy::Client::Snapshots, :vcr do
133
133
  end
134
134
  describe '#finalize_snapshot' do
135
135
  it 'finalizes a snapshot' do
136
- build = Percy.create_build('fotinakis/percy-examples')
136
+ build = Percy.create_build()
137
137
  resources = []
138
138
  resources << Percy::Client::Resource.new('/foo/test.html', sha: sha, is_root: true)
139
139
  resources << Percy::Client::Resource.new('/css/test.css', sha: sha)
@@ -7,14 +7,12 @@ RSpec.describe Percy::Config do
7
7
  :access_token,
8
8
  :api_url,
9
9
  :debug,
10
- :repo,
11
10
  :default_widths,
12
11
  ],
13
12
  )
14
13
  expect(config.access_token).to be_nil
15
14
  expect(config.api_url).to eq(ENV['PERCY_API'])
16
15
  expect(config.debug).to eq(false)
17
- expect(config.repo).to eq('percy/percy-client')
18
16
  expect(config.default_widths).to eq([])
19
17
  end
20
18
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: percy-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.15.0
4
+ version: 2.0.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: 2018-07-26 00:00:00.000000000 Z
11
+ date: 2018-08-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -166,6 +166,7 @@ files:
166
166
  - percy-client.gemspec
167
167
  - spec/cassettes/Percy_Client_Builds/_create_build/accepts_optional_resources.yml
168
168
  - spec/cassettes/Percy_Client_Builds/_create_build/creates_a_build.yml
169
+ - spec/cassettes/Percy_Client_Builds/_create_build/creates_a_build_with_only_a_token.yml
169
170
  - spec/cassettes/Percy_Client_Builds/_create_build/when_in_a_parallel_test_environment/passes_through_parallelism_variables.yml
170
171
  - spec/cassettes/Percy_Client_Builds/_finalize_build/finalizes_a_build.yml
171
172
  - spec/cassettes/Percy_Client_Resources/_upload_resource/returns_true_with_success.yml
@@ -203,13 +204,14 @@ required_rubygems_version: !ruby/object:Gem::Requirement
203
204
  version: '0'
204
205
  requirements: []
205
206
  rubyforge_project:
206
- rubygems_version: 2.6.14
207
+ rubygems_version: 2.7.6
207
208
  signing_key:
208
209
  specification_version: 4
209
210
  summary: Percy::Client
210
211
  test_files:
211
212
  - spec/cassettes/Percy_Client_Builds/_create_build/accepts_optional_resources.yml
212
213
  - spec/cassettes/Percy_Client_Builds/_create_build/creates_a_build.yml
214
+ - spec/cassettes/Percy_Client_Builds/_create_build/creates_a_build_with_only_a_token.yml
213
215
  - spec/cassettes/Percy_Client_Builds/_create_build/when_in_a_parallel_test_environment/passes_through_parallelism_variables.yml
214
216
  - spec/cassettes/Percy_Client_Builds/_finalize_build/finalizes_a_build.yml
215
217
  - spec/cassettes/Percy_Client_Resources/_upload_resource/returns_true_with_success.yml