shipit-engine 0.36.1 → 0.37.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
2
  SHA256:
3
- metadata.gz: 17cf66ed4359907e35e37a0ac00bcb05884c24148386bf8712d8b73c3cc33708
4
- data.tar.gz: b21d35454c554c7faccad5236333cefc3270434617e4bd192372c0a8baa66ac1
3
+ metadata.gz: 174fee8bf3ed460fa137cbe666f639fec2218d0617b4860dcede08d38ed6d93d
4
+ data.tar.gz: 739d8f122ead25b8f1053f954686e4ddd574bc17b544de9b69dce5af7635425c
5
5
  SHA512:
6
- metadata.gz: 1f8e6ba6aaaa5eaa4630cfb52a1445e416e4cb6566550c4a5e2ec447065b2d342c52a728b370552a8b7a2a7df8061c30b0d4987d637729d533fd1bfd907a074a
7
- data.tar.gz: 94abc1c12513349c85d4d54c4668865f21a42bf055d630fca667fd636dd7119b42f31c11f5c2182f2412ed76601adecce38b096a1add9e978dd83279b600d7fb
6
+ metadata.gz: 7b3118fb7bc39e0c8cddad0444d34c39e935bcc192010dec3b27b2bddd9947a770573a959b13fe26661eb8874963b10cdb8ab2382d6eec811ebd8cd87322cc41
7
+ data.tar.gz: cd173c7dc66f31a90e878ed9a2da9724132286c93f2a9c168a5593f81ffbfe3c6f25161095fafe7df1e9d7c2561339ca0c4051ae856c78d8698d382e8d65818c
@@ -62,6 +62,8 @@ module Shipit
62
62
  end
63
63
 
64
64
  def refresh
65
+ RefreshStatusesJob.perform_later(stack_id: stack.id)
66
+ RefreshCheckRunsJob.perform_later(stack_id: stack.id)
65
67
  GithubSyncJob.perform_later(stack_id: stack.id)
66
68
  render_resource(stack, status: :accepted)
67
69
  end
@@ -72,7 +72,14 @@ module Shipit
72
72
  ).run!
73
73
 
74
74
  git_dir = File.join(dir, @stack.repo_name)
75
- git('-c', 'advice.detachedHead=false', 'checkout', commit.sha, chdir: git_dir).run! if commit
75
+ git(
76
+ '-c',
77
+ 'advice.detachedHead=false',
78
+ 'checkout',
79
+ '--quiet',
80
+ commit.sha,
81
+ chdir: git_dir
82
+ ).run! if commit
76
83
  yield Pathname.new(git_dir)
77
84
  end
78
85
  end
@@ -47,7 +47,14 @@ module Shipit
47
47
  end
48
48
 
49
49
  def checkout(commit)
50
- git('-c', 'advice.detachedHead=false', 'checkout', commit.sha, chdir: @task.working_directory)
50
+ git(
51
+ '-c',
52
+ 'advice.detachedHead=false',
53
+ 'checkout',
54
+ '--quiet',
55
+ commit.sha,
56
+ chdir: @task.working_directory
57
+ )
51
58
  end
52
59
 
53
60
  def clone
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Shipit
3
- VERSION = '0.36.1'
3
+ VERSION = '0.37.0'
4
4
  end
@@ -214,6 +214,15 @@ module Shipit
214
214
  end
215
215
  assert_response :accepted
216
216
  end
217
+
218
+ test "#refresh queues a RefreshStatusesJob and RefreshCheckRunsJob" do
219
+ assert_enqueued_with(job: RefreshStatusesJob, args: [stack_id: @stack.id]) do
220
+ assert_enqueued_with(job: RefreshCheckRunsJob, args: [stack_id: @stack.id]) do
221
+ post :refresh, params: { id: @stack.to_param }
222
+ end
223
+ end
224
+ assert_response :accepted
225
+ end
217
226
  end
218
227
  end
219
228
  end
@@ -134,7 +134,11 @@ module Shipit
134
134
 
135
135
  test "#checkout checks out the deployed commit" do
136
136
  command = @commands.checkout(@deploy.until_commit)
137
- assert_equal ['git', '-c', 'advice.detachedHead=false', 'checkout', @deploy.until_commit.sha], command.args
137
+ checkout_args = [
138
+ 'git', '-c', 'advice.detachedHead=false', 'checkout', '--quiet',
139
+ @deploy.until_commit.sha,
140
+ ]
141
+ assert_equal checkout_args, command.args
138
142
  end
139
143
 
140
144
  test "#checkout checks out the deployed commit from the working directory" do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shipit-engine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.36.1
4
+ version: 0.37.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jean Boussier
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-07-13 00:00:00.000000000 Z
11
+ date: 2022-08-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: active_model_serializers
@@ -38,20 +38,6 @@ dependencies:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: 0.0.6
41
- - !ruby/object:Gem::Dependency
42
- name: attr_encrypted
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: 3.1.0
48
- type: :runtime
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: 3.1.0
55
41
  - !ruby/object:Gem::Dependency
56
42
  name: autoprefixer-rails
57
43
  requirement: !ruby/object:Gem::Requirement