shipit-engine 0.35.1 → 0.36.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +7 -7
  3. data/app/controllers/concerns/shipit/authentication.rb +5 -1
  4. data/app/controllers/shipit/api/base_controller.rb +13 -1
  5. data/app/controllers/shipit/api/rollbacks_controller.rb +1 -1
  6. data/app/controllers/shipit/api/stacks_controller.rb +8 -2
  7. data/app/controllers/shipit/api/tasks_controller.rb +19 -2
  8. data/app/helpers/shipit/stacks_helper.rb +11 -0
  9. data/app/models/concerns/shipit/deferred_touch.rb +3 -3
  10. data/app/models/shipit/anonymous_user.rb +4 -0
  11. data/app/models/shipit/commit_checks.rb +3 -3
  12. data/app/models/shipit/task.rb +3 -3
  13. data/app/models/shipit/user.rb +23 -9
  14. data/app/serializers/shipit/stack_serializer.rb +1 -1
  15. data/app/views/shipit/deploys/_deploy.html.erb +1 -5
  16. data/app/views/shipit/stacks/_banners.html.erb +1 -1
  17. data/app/views/shipit/stacks/_settings_form.erb +55 -0
  18. data/app/views/shipit/stacks/settings.html.erb +1 -55
  19. data/app/views/shipit/stacks/show.html.erb +1 -1
  20. data/config/locales/en.yml +1 -1
  21. data/config/routes.rb +4 -0
  22. data/db/migrate/20211103154121_increase_github_team_slug_size.rb +5 -0
  23. data/lib/shipit/engine.rb +13 -5
  24. data/lib/shipit/stack_commands.rb +1 -1
  25. data/lib/shipit/version.rb +1 -1
  26. data/lib/shipit.rb +5 -2
  27. data/test/controllers/api/hooks_controller_test.rb +1 -1
  28. data/test/controllers/api/rollback_controller_test.rb +1 -0
  29. data/test/controllers/api/stacks_controller_test.rb +25 -0
  30. data/test/controllers/api/tasks_controller_test.rb +56 -0
  31. data/test/controllers/stacks_controller_test.rb +11 -0
  32. data/test/dummy/config/application.rb +1 -2
  33. data/test/dummy/db/schema.rb +2 -2
  34. data/test/fixtures/shipit/check_runs.yml +3 -3
  35. data/test/fixtures/shipit/commits.yml +101 -101
  36. data/test/fixtures/shipit/deliveries.yml +1 -1
  37. data/test/fixtures/shipit/merge_requests.yml +19 -19
  38. data/test/fixtures/shipit/stacks.yml +28 -28
  39. data/test/fixtures/shipit/statuses.yml +16 -16
  40. data/test/fixtures/shipit/tasks.yml +65 -65
  41. data/test/fixtures/shipit/users.yml +2 -5
  42. data/test/models/commits_test.rb +6 -6
  43. data/test/models/tasks_test.rb +2 -2
  44. data/test/models/team_test.rb +21 -2
  45. data/test/models/users_test.rb +29 -9
  46. data/test/unit/deploy_commands_test.rb +1 -1
  47. metadata +175 -173
@@ -96,6 +96,24 @@ module Shipit
96
96
  assert_equal 'test', @stack.branch
97
97
  end
98
98
 
99
+ test "#update updates the stack when nil deploy_url" do
100
+ @stack.update(deploy_url: nil)
101
+ @stack.update(continuous_deployment: true)
102
+ assert_nil @stack.deploy_url
103
+ assert @stack.continuous_deployment
104
+
105
+ patch :update, params: {
106
+ id: @stack.to_param,
107
+ continuous_deployment: false,
108
+ }
109
+
110
+ assert_response :ok
111
+ @stack.reload
112
+
113
+ assert_nil @stack.deploy_url
114
+ refute @stack.continuous_deployment
115
+ end
116
+
99
117
  test "#index returns a list of stacks" do
100
118
  stack = Stack.last
101
119
  get :index
@@ -189,6 +207,13 @@ module Shipit
189
207
  assert_response :forbidden
190
208
  assert_json 'message', 'This operation requires the `write:stack` permission'
191
209
  end
210
+
211
+ test "#refresh queues a GithubSyncJob" do
212
+ assert_enqueued_with(job: GithubSyncJob, args: [id: @stack.id]) do
213
+ post :refresh, params: { id: @stack.to_param }
214
+ end
215
+ assert_response :accepted
216
+ end
192
217
  end
193
218
  end
194
219
  end
@@ -6,6 +6,7 @@ module Shipit
6
6
  class TasksControllerTest < ActionController::TestCase
7
7
  setup do
8
8
  @stack = shipit_stacks(:shipit)
9
+ @user = shipit_users(:walrus)
9
10
  authenticate!
10
11
  end
11
12
 
@@ -90,6 +91,61 @@ module Shipit
90
91
  assert_response :conflict
91
92
  assert_json 'message', 'A task is already running.'
92
93
  end
94
+
95
+ test "#trigger fails when user does not have deploy permission" do
96
+ @client.permissions.delete('deploy:stack')
97
+ @client.save!
98
+
99
+ assert_no_difference 'Task.count' do
100
+ post :trigger, params: { stack_id: @stack.to_param, task_name: 'restart' }
101
+ end
102
+
103
+ assert_response :forbidden
104
+ assert_json 'message', 'This operation requires the `deploy:stack` permission'
105
+ end
106
+
107
+ test "#abort aborts the task" do
108
+ task = shipit_deploys(:shipit_running)
109
+ task.ping
110
+
111
+ put :abort, params: { stack_id: @stack.to_param, id: task.id }
112
+
113
+ assert_response :accepted
114
+ assert_equal 'aborting', task.reload.status
115
+ end
116
+
117
+ test "#abort sets `aborted_by` to the current user" do
118
+ task = shipit_deploys(:shipit_running)
119
+ task.ping
120
+ request.headers['X-Shipit-User'] = @user.login
121
+
122
+ put :abort, params: { stack_id: @stack.to_param, id: task.id }
123
+
124
+ assert_equal task.reload.aborted_by, @user
125
+ end
126
+
127
+ test "#abort responds with method_not_allowed if the task is not currently running" do
128
+ task = shipit_deploys(:shipit_aborted)
129
+ task.ping
130
+ put :abort, params: { stack_id: @stack.to_param, id: task.id }
131
+
132
+ assert_response :method_not_allowed
133
+ assert_json 'message', 'This task is not currently running.'
134
+ end
135
+
136
+ test "#abort fails when user does not have deploy permission" do
137
+ @client.permissions.delete('deploy:stack')
138
+ @client.save!
139
+ task = shipit_deploys(:shipit_running)
140
+ task.ping
141
+
142
+ assert_no_difference 'Task.count' do
143
+ put :abort, params: { stack_id: @stack.to_param, id: task.id }
144
+ end
145
+
146
+ assert_response :forbidden
147
+ assert_json 'message', 'This operation requires the `deploy:stack` permission'
148
+ end
93
149
  end
94
150
  end
95
151
  end
@@ -36,6 +36,17 @@ module Shipit
36
36
  assert_redirected_to '/github/auth/github?origin=http%3A%2F%2Ftest.host%2F'
37
37
  end
38
38
 
39
+ test "users which require a fresh login are redirected" do
40
+ user = shipit_users(:walrus)
41
+ user.update!(github_access_token: 'some_legacy_value')
42
+ assert_predicate user, :requires_fresh_login?
43
+
44
+ get :index
45
+
46
+ assert_redirected_to '/github/auth/github?origin=http%3A%2F%2Ftest.host%2F'
47
+ assert_nil session[:user_id]
48
+ end
49
+
39
50
  test "current_user must be a member of at least a Shipit.github_teams" do
40
51
  session[:user_id] = shipit_users(:bob).id
41
52
  Shipit.stubs(:github_teams).returns([shipit_teams(:cyclimse_cooks), shipit_teams(:shopify_developers)])
@@ -17,7 +17,6 @@ end
17
17
 
18
18
  module Shipit
19
19
  class Application < Rails::Application
20
- config.load_defaults 6.1
20
+ config.load_defaults 7.0
21
21
  end
22
22
  end
23
-
@@ -10,7 +10,7 @@
10
10
  #
11
11
  # It's strongly recommended that you check this file into your version control system.
12
12
 
13
- ActiveRecord::Schema.define(version: 2021_08_23_075617) do
13
+ ActiveRecord::Schema.define(version: 2021_11_03_154121) do
14
14
 
15
15
  create_table "api_clients", force: :cascade do |t|
16
16
  t.text "permissions", limit: 65535
@@ -315,7 +315,7 @@ ActiveRecord::Schema.define(version: 2021_08_23_075617) do
315
315
  create_table "teams", force: :cascade do |t|
316
316
  t.integer "github_id", limit: 4
317
317
  t.string "api_url", limit: 255
318
- t.string "slug", limit: 50
318
+ t.string "slug", limit: 255
319
319
  t.string "name", limit: 255
320
320
  t.string "organization", limit: 39
321
321
  t.datetime "created_at", null: false
@@ -7,7 +7,7 @@ second_pending_travis:
7
7
  conclusion: success
8
8
  html_url: "http://www.example.com/run/424242"
9
9
  details_url: "http://www.example.com/build/424242"
10
- created_at: <%= 10.days.ago.to_s(:db) %>
10
+ created_at: <%= 10.days.ago.to_formatted_s(:db) %>
11
11
 
12
12
  check_runs_first_pending_coveralls:
13
13
  stack: check_runs
@@ -15,7 +15,7 @@ check_runs_first_pending_coveralls:
15
15
  github_id: 43
16
16
  title: lets go
17
17
  name: Coverage metrics
18
- created_at: <%= 10.days.ago.to_s(:db) %>
18
+ created_at: <%= 10.days.ago.to_formatted_s(:db) %>
19
19
  conclusion: pending
20
20
  html_url: "http://www.example.com/run/434343"
21
21
  details_url: "http://www.example.com/build/434343"
@@ -26,7 +26,7 @@ check_runs_first_success_coveralls:
26
26
  github_id: 434343
27
27
  title: lets go
28
28
  name: Coverage metrics
29
- created_at: <%= 9.days.ago.to_s(:db) %>
29
+ created_at: <%= 9.days.ago.to_formatted_s(:db) %>
30
30
  conclusion: success
31
31
  html_url: "http://www.example.com/run/434343"
32
32
  details_url: "http://www.example.com/build/434343"
@@ -5,12 +5,12 @@ first:
5
5
  stack: shipit
6
6
  author: walrus
7
7
  committer: walrus
8
- authored_at: <%= 10.days.ago.to_s(:db) %>
9
- committed_at: <%= 9.days.ago.to_s(:db) %>
8
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
9
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
10
10
  additions: 42
11
11
  deletions: 24
12
- updated_at: <%= 8.days.ago.to_s(:db) %>
13
- created_at: <%= 1.day.ago.to_s(:db) %>
12
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
13
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
14
14
 
15
15
  second:
16
16
  id: 2
@@ -19,12 +19,12 @@ second:
19
19
  stack: shipit
20
20
  author: walrus
21
21
  committer: walrus
22
- authored_at: <%= 8.days.ago.to_s(:db) %>
23
- committed_at: <%= 7.days.ago.to_s(:db) %>
22
+ authored_at: <%= 8.days.ago.to_formatted_s(:db) %>
23
+ committed_at: <%= 7.days.ago.to_formatted_s(:db) %>
24
24
  additions: 1
25
25
  deletions: 1
26
- updated_at: <%= 8.days.ago.to_s(:db) %>
27
- created_at: <%= 1.day.ago.to_s(:db) %>
26
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
27
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
28
28
 
29
29
  third:
30
30
  id: 3
@@ -33,12 +33,12 @@ third:
33
33
  stack: shipit
34
34
  author: walrus
35
35
  committer: walrus
36
- authored_at: <%= 6.days.ago.to_s(:db) %>
37
- committed_at: <%= 5.days.ago.to_s(:db) %>
36
+ authored_at: <%= 6.days.ago.to_formatted_s(:db) %>
37
+ committed_at: <%= 5.days.ago.to_formatted_s(:db) %>
38
38
  additions: 12
39
39
  deletions: 64
40
- updated_at: <%= 8.days.ago.to_s(:db) %>
41
- created_at: <%= 1.day.ago.to_s(:db) %>
40
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
41
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
42
42
 
43
43
  fourth:
44
44
  id: 4
@@ -47,12 +47,12 @@ fourth:
47
47
  stack: shipit
48
48
  author: ~
49
49
  committer: ~
50
- authored_at: <%= 4.days.ago.to_s(:db) %>
51
- committed_at: <%= 3.days.ago.to_s(:db) %>
50
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
51
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
52
52
  additions: 420
53
53
  deletions: 342
54
- updated_at: <%= 8.days.ago.to_s(:db) %>
55
- created_at: <%= 1.day.ago.to_s(:db) %>
54
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
55
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
56
56
  pull_request_head_sha: '6dcb09b5b57875f334f61aebed695e2e4193db5e'
57
57
 
58
58
  fifth:
@@ -62,12 +62,12 @@ fifth:
62
62
  stack: shipit
63
63
  author: walrus
64
64
  committer: walrus
65
- authored_at: <%= 2.days.ago.to_s(:db) %>
66
- committed_at: <%= 1.days.ago.to_s(:db) %>
65
+ authored_at: <%= 2.days.ago.to_formatted_s(:db) %>
66
+ committed_at: <%= 1.days.ago.to_formatted_s(:db) %>
67
67
  additions: 1
68
68
  deletions: 24
69
- updated_at: <%= 8.days.ago.to_s(:db) %>
70
- created_at: <%= 1.day.ago.to_s(:db) %>
69
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
70
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
71
71
 
72
72
  cyclimse_first:
73
73
  id: 6
@@ -76,11 +76,11 @@ cyclimse_first:
76
76
  stack: cyclimse
77
77
  author: bob
78
78
  committer: bob
79
- authored_at: <%= 2.days.ago.to_s(:db) %>
80
- committed_at: <%= 1.days.ago.to_s(:db) %>
79
+ authored_at: <%= 2.days.ago.to_formatted_s(:db) %>
80
+ committed_at: <%= 1.days.ago.to_formatted_s(:db) %>
81
81
  additions: 1
82
82
  deletions: 24
83
- updated_at: <%= 8.days.ago.to_s(:db) %>
83
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
84
84
 
85
85
  undeployed_stack_first:
86
86
  id: 7
@@ -89,11 +89,11 @@ undeployed_stack_first:
89
89
  stack: undeployed_stack
90
90
  author: bob
91
91
  committer: bob
92
- authored_at: <%= 2.days.ago.to_s(:db) %>
93
- committed_at: <%= 1.days.ago.to_s(:db) %>
92
+ authored_at: <%= 2.days.ago.to_formatted_s(:db) %>
93
+ committed_at: <%= 1.days.ago.to_formatted_s(:db) %>
94
94
  additions: 1
95
95
  deletions: 24
96
- updated_at: <%= 8.days.ago.to_s(:db) %>
96
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
97
97
 
98
98
  shipit_pending_pr_head:
99
99
  id: 8
@@ -102,11 +102,11 @@ shipit_pending_pr_head:
102
102
  stack: shipit
103
103
  author: walrus
104
104
  committer: walrus
105
- authored_at: <%= 10.days.ago.to_s(:db) %>
106
- committed_at: <%= 9.days.ago.to_s(:db) %>
105
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
106
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
107
107
  additions: 42
108
108
  deletions: 24
109
- updated_at: <%= 8.days.ago.to_s(:db) %>
109
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
110
110
  detached: true
111
111
 
112
112
  cyclimse_merged:
@@ -116,11 +116,11 @@ cyclimse_merged:
116
116
  stack: cyclimse
117
117
  author: walrus
118
118
  committer: walrus
119
- authored_at: <%= 4.days.ago.to_s(:db) %>
120
- committed_at: <%= 3.days.ago.to_s(:db) %>
119
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
120
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
121
121
  additions: 420
122
122
  deletions: 342
123
- updated_at: <%= 8.days.ago.to_s(:db) %>
123
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
124
124
  merge_request_id: 99
125
125
 
126
126
  anonymous:
@@ -130,11 +130,11 @@ anonymous:
130
130
  stack: shipit
131
131
  author:
132
132
  committer:
133
- authored_at: <%= 10.days.ago.to_s(:db) %>
134
- committed_at: <%= 9.days.ago.to_s(:db) %>
133
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
134
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
135
135
  additions: 42
136
136
  deletions: 24
137
- updated_at: <%= 8.days.ago.to_s(:db) %>
137
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
138
138
 
139
139
  soc_first:
140
140
  id: 101
@@ -143,11 +143,11 @@ soc_first:
143
143
  stack: soc
144
144
  author: walrus
145
145
  committer: walrus
146
- authored_at: <%= 10.days.ago.to_s(:db) %>
147
- committed_at: <%= 9.days.ago.to_s(:db) %>
146
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
147
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
148
148
  additions: 42
149
149
  deletions: 24
150
- updated_at: <%= 8.days.ago.to_s(:db) %>
150
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
151
151
 
152
152
  soc_second:
153
153
  id: 102
@@ -156,11 +156,11 @@ soc_second:
156
156
  stack: soc
157
157
  author: walrus
158
158
  committer: walrus
159
- authored_at: <%= 8.days.ago.to_s(:db) %>
160
- committed_at: <%= 7.days.ago.to_s(:db) %>
159
+ authored_at: <%= 8.days.ago.to_formatted_s(:db) %>
160
+ committed_at: <%= 7.days.ago.to_formatted_s(:db) %>
161
161
  additions: 1
162
162
  deletions: 1
163
- updated_at: <%= 8.days.ago.to_s(:db) %>
163
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
164
164
 
165
165
  soc_third:
166
166
  id: 103
@@ -169,11 +169,11 @@ soc_third:
169
169
  stack: soc
170
170
  author: walrus
171
171
  committer: walrus
172
- authored_at: <%= 6.days.ago.to_s(:db) %>
173
- committed_at: <%= 5.days.ago.to_s(:db) %>
172
+ authored_at: <%= 6.days.ago.to_formatted_s(:db) %>
173
+ committed_at: <%= 5.days.ago.to_formatted_s(:db) %>
174
174
  additions: 12
175
175
  deletions: 64
176
- updated_at: <%= 8.days.ago.to_s(:db) %>
176
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
177
177
 
178
178
  check_runs_first:
179
179
  id: 201
@@ -182,11 +182,11 @@ check_runs_first:
182
182
  stack: check_runs
183
183
  author: walrus
184
184
  committer: walrus
185
- authored_at: <%= 10.days.ago.to_s(:db) %>
186
- committed_at: <%= 9.days.ago.to_s(:db) %>
185
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
186
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
187
187
  additions: 42
188
188
  deletions: 24
189
- updated_at: <%= 8.days.ago.to_s(:db) %>
189
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
190
190
 
191
191
  canaries_first:
192
192
  id: 301
@@ -195,12 +195,12 @@ canaries_first:
195
195
  stack: shipit_canaries
196
196
  author: walrus
197
197
  committer: walrus
198
- authored_at: <%= 10.days.ago.to_s(:db) %>
199
- committed_at: <%= 9.days.ago.to_s(:db) %>
198
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
199
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
200
200
  additions: 42
201
201
  deletions: 24
202
- updated_at: <%= 8.days.ago.to_s(:db) %>
203
- created_at: <%= 1.day.ago.to_s(:db) %>
202
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
203
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
204
204
 
205
205
  canaries_second:
206
206
  id: 302
@@ -209,12 +209,12 @@ canaries_second:
209
209
  stack: shipit_canaries
210
210
  author: walrus
211
211
  committer: walrus
212
- authored_at: <%= 8.days.ago.to_s(:db) %>
213
- committed_at: <%= 7.days.ago.to_s(:db) %>
212
+ authored_at: <%= 8.days.ago.to_formatted_s(:db) %>
213
+ committed_at: <%= 7.days.ago.to_formatted_s(:db) %>
214
214
  additions: 1
215
215
  deletions: 1
216
- updated_at: <%= 8.days.ago.to_s(:db) %>
217
- created_at: <%= 1.day.ago.to_s(:db) %>
216
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
217
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
218
218
 
219
219
  canaries_third:
220
220
  id: 303
@@ -223,12 +223,12 @@ canaries_third:
223
223
  stack: shipit_canaries
224
224
  author: walrus
225
225
  committer: walrus
226
- authored_at: <%= 6.days.ago.to_s(:db) %>
227
- committed_at: <%= 5.days.ago.to_s(:db) %>
226
+ authored_at: <%= 6.days.ago.to_formatted_s(:db) %>
227
+ committed_at: <%= 5.days.ago.to_formatted_s(:db) %>
228
228
  additions: 12
229
229
  deletions: 64
230
- updated_at: <%= 8.days.ago.to_s(:db) %>
231
- created_at: <%= 1.day.ago.to_s(:db) %>
230
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
231
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
232
232
 
233
233
  canaries_fourth:
234
234
  id: 304
@@ -237,12 +237,12 @@ canaries_fourth:
237
237
  stack: shipit_canaries
238
238
  author: walrus
239
239
  committer: walrus
240
- authored_at: <%= 4.days.ago.to_s(:db) %>
241
- committed_at: <%= 3.days.ago.to_s(:db) %>
240
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
241
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
242
242
  additions: 420
243
243
  deletions: 342
244
- updated_at: <%= 8.days.ago.to_s(:db) %>
245
- created_at: <%= 1.day.ago.to_s(:db) %>
244
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
245
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
246
246
 
247
247
  canaries_fifth:
248
248
  id: 305
@@ -251,12 +251,12 @@ canaries_fifth:
251
251
  stack: shipit_canaries
252
252
  author: walrus
253
253
  committer: walrus
254
- authored_at: <%= 2.days.ago.to_s(:db) %>
255
- committed_at: <%= 1.days.ago.to_s(:db) %>
254
+ authored_at: <%= 2.days.ago.to_formatted_s(:db) %>
255
+ committed_at: <%= 1.days.ago.to_formatted_s(:db) %>
256
256
  additions: 1
257
257
  deletions: 24
258
- updated_at: <%= 8.days.ago.to_s(:db) %>
259
- created_at: <%= 1.day.ago.to_s(:db) %>
258
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
259
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
260
260
 
261
261
  undeployed_1:
262
262
  id: 401
@@ -265,11 +265,11 @@ undeployed_1:
265
265
  stack: shipit_undeployed
266
266
  author: walrus
267
267
  committer: walrus
268
- authored_at: <%= 10.days.ago.to_s(:db) %>
269
- committed_at: <%= 9.days.ago.to_s(:db) %>
268
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
269
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
270
270
  additions: 42
271
271
  deletions: 24
272
- updated_at: <%= 8.days.ago.to_s(:db) %>
272
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
273
273
 
274
274
  undeployed_2:
275
275
  id: 402
@@ -278,11 +278,11 @@ undeployed_2:
278
278
  stack: shipit_undeployed
279
279
  author: walrus
280
280
  committer: walrus
281
- authored_at: <%= 8.days.ago.to_s(:db) %>
282
- committed_at: <%= 7.days.ago.to_s(:db) %>
281
+ authored_at: <%= 8.days.ago.to_formatted_s(:db) %>
282
+ committed_at: <%= 7.days.ago.to_formatted_s(:db) %>
283
283
  additions: 1
284
284
  deletions: 1
285
- updated_at: <%= 8.days.ago.to_s(:db) %>
285
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
286
286
 
287
287
  undeployed_3:
288
288
  id: 403
@@ -291,11 +291,11 @@ undeployed_3:
291
291
  stack: shipit_undeployed
292
292
  author: walrus
293
293
  committer: walrus
294
- authored_at: <%= 6.days.ago.to_s(:db) %>
295
- committed_at: <%= 5.days.ago.to_s(:db) %>
294
+ authored_at: <%= 6.days.ago.to_formatted_s(:db) %>
295
+ committed_at: <%= 5.days.ago.to_formatted_s(:db) %>
296
296
  additions: 12
297
297
  deletions: 64
298
- updated_at: <%= 8.days.ago.to_s(:db) %>
298
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
299
299
 
300
300
  undeployed_4:
301
301
  id: 404
@@ -304,11 +304,11 @@ undeployed_4:
304
304
  stack: shipit_undeployed
305
305
  author: walrus
306
306
  committer: walrus
307
- authored_at: <%= 4.days.ago.to_s(:db) %>
308
- committed_at: <%= 3.days.ago.to_s(:db) %>
307
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
308
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
309
309
  additions: 420
310
310
  deletions: 342
311
- updated_at: <%= 8.days.ago.to_s(:db) %>
311
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
312
312
 
313
313
  undeployed_5:
314
314
  id: 405
@@ -317,11 +317,11 @@ undeployed_5:
317
317
  stack: shipit_undeployed
318
318
  author: walrus
319
319
  committer: walrus
320
- authored_at: <%= 4.days.ago.to_s(:db) %>
321
- committed_at: <%= 3.days.ago.to_s(:db) %>
320
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
321
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
322
322
  additions: 420
323
323
  deletions: 342
324
- updated_at: <%= 8.days.ago.to_s(:db) %>
324
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
325
325
 
326
326
  undeployed_6:
327
327
  id: 406
@@ -330,11 +330,11 @@ undeployed_6:
330
330
  stack: shipit_undeployed
331
331
  author: walrus
332
332
  committer: walrus
333
- authored_at: <%= 4.days.ago.to_s(:db) %>
334
- committed_at: <%= 3.days.ago.to_s(:db) %>
333
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
334
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
335
335
  additions: 420
336
336
  deletions: 342
337
- updated_at: <%= 8.days.ago.to_s(:db) %>
337
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
338
338
 
339
339
  undeployed_7:
340
340
  id: 407
@@ -343,11 +343,11 @@ undeployed_7:
343
343
  stack: shipit_undeployed
344
344
  author: walrus
345
345
  committer: walrus
346
- authored_at: <%= 4.days.ago.to_s(:db) %>
347
- committed_at: <%= 3.days.ago.to_s(:db) %>
346
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
347
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
348
348
  additions: 420
349
349
  deletions: 342
350
- updated_at: <%= 8.days.ago.to_s(:db) %>
350
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
351
351
 
352
352
  single:
353
353
  id: 501
@@ -356,11 +356,11 @@ single:
356
356
  stack: shipit_single
357
357
  author: walrus
358
358
  committer: walrus
359
- authored_at: <%= 4.days.ago.to_s(:db) %>
360
- committed_at: <%= 3.days.ago.to_s(:db) %>
359
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
360
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
361
361
  additions: 420
362
362
  deletions: 342
363
- updated_at: <%= 8.days.ago.to_s(:db) %>
363
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
364
364
 
365
365
  task_no_commits:
366
366
  id: 601
@@ -369,11 +369,11 @@ task_no_commits:
369
369
  stack: shipit_task_no_commits
370
370
  author: walrus
371
371
  committer: walrus
372
- authored_at: <%= 4.days.ago.to_s(:db) %>
373
- committed_at: <%= 3.days.ago.to_s(:db) %>
372
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
373
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
374
374
  additions: 420
375
375
  deletions: 342
376
- updated_at: <%= 8.days.ago.to_s(:db) %>
376
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
377
377
 
378
378
  check_deploy_spec_first:
379
379
  id: 701
@@ -382,11 +382,11 @@ check_deploy_spec_first:
382
382
  stack: check_deploy_spec
383
383
  author: walrus
384
384
  committer: walrus
385
- authored_at: <%= 4.days.ago.to_s(:db) %>
386
- committed_at: <%= 3.days.ago.to_s(:db) %>
385
+ authored_at: <%= 4.days.ago.to_formatted_s(:db) %>
386
+ committed_at: <%= 3.days.ago.to_formatted_s(:db) %>
387
387
  additions: 420
388
388
  deletions: 342
389
- updated_at: <%= 8.days.ago.to_s(:db) %>
389
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
390
390
 
391
391
  deployable_review_stack_commit:
392
392
  id: 801
@@ -395,9 +395,9 @@ deployable_review_stack_commit:
395
395
  stack: review_stack
396
396
  author: walrus
397
397
  committer: walrus
398
- authored_at: <%= 10.days.ago.to_s(:db) %>
399
- committed_at: <%= 9.days.ago.to_s(:db) %>
398
+ authored_at: <%= 10.days.ago.to_formatted_s(:db) %>
399
+ committed_at: <%= 9.days.ago.to_formatted_s(:db) %>
400
400
  additions: 42
401
401
  deletions: 24
402
- updated_at: <%= 8.days.ago.to_s(:db) %>
403
- created_at: <%= 1.day.ago.to_s(:db) %>
402
+ updated_at: <%= 8.days.ago.to_formatted_s(:db) %>
403
+ created_at: <%= 1.day.ago.to_formatted_s(:db) %>
@@ -11,4 +11,4 @@ scheduled_shipit_deploy:
11
11
  "deploy": {
12
12
  }
13
13
  }
14
- created_at: <%= 5.minutes.ago.to_s(:db) %>
14
+ created_at: <%= 5.minutes.ago.to_formatted_s(:db) %>