heroku_hatchet 7.1.2 → 7.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.circleci/config.yml +5 -5
- data/.github/workflows/check_changelog.yml +3 -2
- data/CHANGELOG.md +40 -0
- data/README.md +62 -4
- data/bin/hatchet +7 -1
- data/hatchet.gemspec +2 -2
- data/lib/hatchet.rb +22 -1
- data/lib/hatchet/app.rb +110 -73
- data/lib/hatchet/config.rb +1 -1
- data/lib/hatchet/git_app.rb +14 -10
- data/lib/hatchet/heroku_run.rb +96 -0
- data/lib/hatchet/init_project.rb +86 -0
- data/lib/hatchet/reaper.rb +2 -2
- data/lib/hatchet/templates/Gemfile.erb +5 -0
- data/lib/hatchet/templates/buildpack_spec.erb +23 -0
- data/lib/hatchet/templates/check_changelog.erb +13 -0
- data/lib/hatchet/templates/circleci_template.erb +45 -0
- data/lib/hatchet/templates/dependabot.erb +9 -0
- data/lib/hatchet/templates/hatchet_json.erb +11 -0
- data/lib/hatchet/templates/spec_helper.erb +30 -0
- data/lib/hatchet/test_run.rb +17 -12
- data/lib/hatchet/version.rb +1 -1
- data/spec/hatchet/allow_failure_git_spec.rb +1 -1
- data/spec/hatchet/app_spec.rb +95 -26
- data/spec/hatchet/git_spec.rb +6 -0
- data/spec/hatchet/local_repo_spec.rb +17 -7
- data/spec/hatchet/lock_spec.rb +1 -1
- data/spec/spec_helper.rb +2 -1
- data/spec/unit/heroku_run_spec.rb +115 -0
- data/spec/unit/init_spec.rb +52 -0
- data/spec/unit/shell_throttle_spec.rb +94 -0
- metadata +21 -22
- data/spec/unit/shell_throttle.rb +0 -28
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heroku_hatchet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 7.
|
4
|
+
version: 7.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Schneeman
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-10-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: platform-api
|
@@ -58,14 +58,14 @@ dependencies:
|
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
61
|
+
version: '1'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '1'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: threaded
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -136,20 +136,6 @@ dependencies:
|
|
136
136
|
- - ">="
|
137
137
|
- !ruby/object:Gem::Version
|
138
138
|
version: '0'
|
139
|
-
- !ruby/object:Gem::Dependency
|
140
|
-
name: travis
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
142
|
-
requirements:
|
143
|
-
- - ">="
|
144
|
-
- !ruby/object:Gem::Version
|
145
|
-
version: '1'
|
146
|
-
type: :development
|
147
|
-
prerelease: false
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
149
|
-
requirements:
|
150
|
-
- - ">="
|
151
|
-
- !ruby/object:Gem::Version
|
152
|
-
version: '1'
|
153
139
|
- !ruby/object:Gem::Dependency
|
154
140
|
name: rspec-retry
|
155
141
|
requirement: !ruby/object:Gem::Requirement
|
@@ -192,11 +178,20 @@ files:
|
|
192
178
|
- lib/hatchet/app.rb
|
193
179
|
- lib/hatchet/config.rb
|
194
180
|
- lib/hatchet/git_app.rb
|
181
|
+
- lib/hatchet/heroku_run.rb
|
182
|
+
- lib/hatchet/init_project.rb
|
195
183
|
- lib/hatchet/reaper.rb
|
196
184
|
- lib/hatchet/reaper/app_age.rb
|
197
185
|
- lib/hatchet/reaper/reaper_throttle.rb
|
198
186
|
- lib/hatchet/shell_throttle.rb
|
199
187
|
- lib/hatchet/tasks.rb
|
188
|
+
- lib/hatchet/templates/Gemfile.erb
|
189
|
+
- lib/hatchet/templates/buildpack_spec.erb
|
190
|
+
- lib/hatchet/templates/check_changelog.erb
|
191
|
+
- lib/hatchet/templates/circleci_template.erb
|
192
|
+
- lib/hatchet/templates/dependabot.erb
|
193
|
+
- lib/hatchet/templates/hatchet_json.erb
|
194
|
+
- lib/hatchet/templates/spec_helper.erb
|
200
195
|
- lib/hatchet/test_run.rb
|
201
196
|
- lib/hatchet/version.rb
|
202
197
|
- repo_fixtures/different-folder-for-checked-in-repos/default_ruby/Gemfile
|
@@ -211,8 +206,10 @@ files:
|
|
211
206
|
- spec/hatchet/local_repo_spec.rb
|
212
207
|
- spec/hatchet/lock_spec.rb
|
213
208
|
- spec/spec_helper.rb
|
209
|
+
- spec/unit/heroku_run_spec.rb
|
210
|
+
- spec/unit/init_spec.rb
|
214
211
|
- spec/unit/reaper_spec.rb
|
215
|
-
- spec/unit/
|
212
|
+
- spec/unit/shell_throttle_spec.rb
|
216
213
|
- tmp/parallel_runtime_test.log
|
217
214
|
homepage: https://github.com/heroku/hatchet
|
218
215
|
licenses:
|
@@ -226,14 +223,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
226
223
|
requirements:
|
227
224
|
- - ">="
|
228
225
|
- !ruby/object:Gem::Version
|
229
|
-
version:
|
226
|
+
version: 2.2.0
|
230
227
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
231
228
|
requirements:
|
232
229
|
- - ">="
|
233
230
|
- !ruby/object:Gem::Version
|
234
231
|
version: '0'
|
235
232
|
requirements: []
|
236
|
-
rubygems_version: 3.1.
|
233
|
+
rubygems_version: 3.1.4
|
237
234
|
signing_key:
|
238
235
|
specification_version: 4
|
239
236
|
summary: Hatchet is a an integration testing library for developing Heroku buildpacks.
|
@@ -248,5 +245,7 @@ test_files:
|
|
248
245
|
- spec/hatchet/local_repo_spec.rb
|
249
246
|
- spec/hatchet/lock_spec.rb
|
250
247
|
- spec/spec_helper.rb
|
248
|
+
- spec/unit/heroku_run_spec.rb
|
249
|
+
- spec/unit/init_spec.rb
|
251
250
|
- spec/unit/reaper_spec.rb
|
252
|
-
- spec/unit/
|
251
|
+
- spec/unit/shell_throttle_spec.rb
|
data/spec/unit/shell_throttle.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
require "spec_helper"
|
2
|
-
|
3
|
-
describe "ShellThrottle" do
|
4
|
-
it "throttles when throw is called" do
|
5
|
-
platform_api = Hatchet::Runner.new("default_ruby").platform_api
|
6
|
-
|
7
|
-
@count = 0
|
8
|
-
Hatchet::ShellThrottle.new(platform_api: platform_api).call do
|
9
|
-
@count += 1
|
10
|
-
if @count >= 2
|
11
|
-
# No throttle
|
12
|
-
else
|
13
|
-
throw(:throttle)
|
14
|
-
end
|
15
|
-
end
|
16
|
-
expect(@count).to eq(2)
|
17
|
-
end
|
18
|
-
|
19
|
-
it "does not throttle when throw is NOT called" do
|
20
|
-
platform_api = Hatchet::Runner.new("default_ruby").platform_api
|
21
|
-
|
22
|
-
@count = 0
|
23
|
-
Hatchet::ShellThrottle.new(platform_api: platform_api).call do
|
24
|
-
@count += 1
|
25
|
-
end
|
26
|
-
expect(@count).to eq(1)
|
27
|
-
end
|
28
|
-
end
|