11Feature : App type is set correctly for integrations in a Rails app
22
3- Background :
4- Given I start the rails service
5- And I run the "db:prepare" rake task in the rails app
6- And I run the "db:migrate" rake task in the rails app
7-
83@rails_integrations
94Scenario : Delayed job
5+ Given I start the rails service with the database
6+ And I run the "jobs:work" rake task in the rails app in the background
107 When I run "User.new.delay.raise_the_roof" with the rails runner
11- And I run the "jobs:workoff" rake task in the rails app
128 And I wait to receive an error
139 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
1410 And the event "unhandled" is true
@@ -27,6 +23,7 @@ Scenario: Delayed job
2723
2824@rails_integrations
2925Scenario : Mailman
26+ Given I start the rails service
3027 When I run "./run_mailman" in the rails app
3128 And I wait to receive an error
3229 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
@@ -41,8 +38,9 @@ Scenario: Mailman
4138
4239@rails_integrations
4340Scenario : Que
41+ Given I start the rails service with the database
42+ And I run "bundle exec que ./config/environment.rb" in the rails app in the background
4443 When I run "QueJob.enqueue" with the rails runner
45- And I run "timeout 5 bundle exec que ./config/environment.rb" in the rails app
4644 And I wait to receive an error
4745 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
4846 And the event "unhandled" is true
@@ -56,6 +54,7 @@ Scenario: Que
5654
5755@rails_integrations
5856Scenario : Rake
57+ Given I start the rails service
5958 When I run the "rake_task:raise" rake task in the rails app
6059 And I wait to receive an error
6160 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
@@ -71,8 +70,9 @@ Scenario: Rake
7170
7271@rails_integrations
7372Scenario : Resque (no on_exit hooks)
74- When I run "Resque.enqueue(ResqueWorker, 123, %(abc), x: true, y: false)" with the rails runner
75- And I run "timeout --signal QUIT 5 bundle exec rake resque:work" in the rails app
73+ Given I start the rails service
74+ And I run the "resque:work" rake task in the rails app in the background
75+ When I run the "fixture:queue_resque_job" rake task in the rails app
7676 And I wait to receive an error
7777 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
7878 And the event "unhandled" is true
@@ -87,17 +87,21 @@ Scenario: Resque (no on_exit hooks)
8787 And the event "metaData.payload.class" equals "ResqueWorker"
8888 And the event "metaData.payload.args.0" equals 123
8989 And the event "metaData.payload.args.1" equals "abc"
90- And the event "metaData.payload.args.2.x" is true
91- And the event "metaData.payload.args.2.y" is false
90+ And the event "metaData.payload.args.2.0" equals 7
91+ And the event "metaData.payload.args.2.1" equals 8
92+ And the event "metaData.payload.args.2.2" equals 9
93+ And the event "metaData.payload.args.3.x" is true
94+ And the event "metaData.payload.args.3.y" is false
9295 And the event "metaData.rake_task.name" equals "resque:work"
9396 And the event "metaData.rake_task.description" equals "Start a Resque worker"
9497 And the event "metaData.rake_task.arguments" is null
9598
9699@rails_integrations
97100Scenario : Resque (with on_exit hooks)
98101 Given I set environment variable "RUN_AT_EXIT_HOOKS" to "1"
99- When I run "Resque.enqueue(ResqueWorker, %(xyz), [7, 8, 9], a: 4, b: 5)" with the rails runner
100- And I run "timeout --signal QUIT 5 bundle exec rake resque:work" in the rails app
102+ And I start the rails service
103+ And I run the "resque:work" rake task in the rails app in the background
104+ When I run the "fixture:queue_resque_job" rake task in the rails app
101105 And I wait to receive an error
102106 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
103107 And the event "unhandled" is true
@@ -110,20 +114,22 @@ Scenario: Resque (with on_exit hooks)
110114 And the event "metaData.config.delivery_method" equals "thread_queue"
111115 And the event "metaData.context" equals "ResqueWorker@crash"
112116 And the event "metaData.payload.class" equals "ResqueWorker"
113- And the event "metaData.payload.args.0" equals "xyz"
114- And the event "metaData.payload.args.1.0" equals 7
115- And the event "metaData.payload.args.1.1" equals 8
116- And the event "metaData.payload.args.1.2" equals 9
117- And the event "metaData.payload.args.2.a" equals 4
118- And the event "metaData.payload.args.2.b" equals 5
117+ And the event "metaData.payload.args.0" equals 123
118+ And the event "metaData.payload.args.1" equals "abc"
119+ And the event "metaData.payload.args.2.0" equals 7
120+ And the event "metaData.payload.args.2.1" equals 8
121+ And the event "metaData.payload.args.2.2" equals 9
122+ And the event "metaData.payload.args.3.x" is true
123+ And the event "metaData.payload.args.3.y" is false
119124 And the event "metaData.rake_task.name" equals "resque:work"
120125 And the event "metaData.rake_task.description" equals "Start a Resque worker"
121126 And the event "metaData.rake_task.arguments" is null
122127
123128@rails_integrations
124129Scenario : Sidekiq
130+ Given I start the rails service
131+ And I run "bundle exec sidekiq" in the rails app in the background
125132 When I run "SidekiqWorker.perform_async" with the rails runner
126- And I run "timeout 5 bundle exec sidekiq" in the rails app
127133 And I wait to receive an error
128134 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
129135 And the event "unhandled" is true
@@ -140,8 +146,9 @@ Scenario: Sidekiq
140146@rails_integrations
141147Scenario : Using Sidekiq as the Active Job queue adapter for a job that raises
142148 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "sidekiq"
143- When I run "UnhandledJob.perform_later(1, yes: true)" with the rails runner
144- And I run "timeout 5 bundle exec sidekiq" in the rails app
149+ And I start the rails service
150+ And I run "bundle exec sidekiq" in the rails app in the background
151+ When I run the "fixture:queue_unhandled_job" rake task in the rails app
145152 And I wait to receive an error
146153 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
147154 And the event "unhandled" is true
@@ -162,8 +169,9 @@ Scenario: Using Sidekiq as the Active Job queue adapter for a job that raises
162169@rails_integrations
163170Scenario : Using Resque as the Active Job queue adapter for a job that raises
164171 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "resque"
165- When I run "UnhandledJob.perform_later(1, yes: true)" with the rails runner
166- And I run "timeout --signal QUIT 5 bundle exec rake resque:work" in the rails app
172+ And I start the rails service
173+ And I run the "resque:work" rake task in the rails app in the background
174+ When I run the "fixture:queue_unhandled_job" rake task in the rails app
167175 And I wait to receive an error
168176 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
169177 And the event "unhandled" is true
@@ -183,8 +191,9 @@ Scenario: Using Resque as the Active Job queue adapter for a job that raises
183191@rails_integrations
184192Scenario : Using Que as the Active Job queue adapter for a job that raises
185193 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "que"
186- When I run "UnhandledJob.perform_later(1, yes: true)" with the rails runner
187- And I run "timeout 5 bundle exec que -q default ./config/environment.rb" in the rails app
194+ And I start the rails service with the database
195+ And I run "bundle exec que -q default ./config/environment.rb" in the rails app in the background
196+ When I run the "fixture:queue_unhandled_job" rake task in the rails app
188197 And I wait to receive an error
189198 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
190199 And the event "unhandled" is true
@@ -204,8 +213,9 @@ Scenario: Using Que as the Active Job queue adapter for a job that raises
204213@rails_integrations
205214Scenario : Using Delayed Job as the Active Job queue adapter for a job that raises
206215 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "delayed_job"
207- And I run "UnhandledJob.perform_later(1, yes: true)" with the rails runner
208- And I run the "jobs:workoff" rake task in the rails app
216+ And I start the rails service with the database
217+ And I run the "jobs:work" rake task in the rails app in the background
218+ When I run the "fixture:queue_unhandled_job" rake task in the rails app
209219 And I wait to receive an error
210220 Then the error is valid for the error reporting API version "4.0" for the "Ruby Bugsnag Notifier" notifier
211221 And the event "unhandled" is true
@@ -225,27 +235,31 @@ Scenario: Using Delayed Job as the Active Job queue adapter for a job that raise
225235@rails_integrations
226236Scenario : Using Sidekiq as the Active Job queue adapter for a job that works
227237 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "sidekiq"
228- And I run "WorkingJob.perform_later" with the rails runner
229- And I run "timeout 5 bundle exec sidekiq" in the rails app
238+ And I start the rails service
239+ And I run "bundle exec sidekiq" in the rails app in the background
240+ When I run the "fixture:queue_working_job" rake task in the rails app
230241 Then I should receive no requests
231242
232243@rails_integrations
233244Scenario : Using Resque as the Active Job queue adapter for a job that works
234245 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "resque"
235- And I run "WorkingJob.perform_later" with the rails runner
236- And I run "timeout --signal QUIT 5 bundle exec rake resque:work" in the rails app
246+ And I start the rails service
247+ And I run "bundle exec rake resque:work" in the rails app in the background
248+ When I run the "fixture:queue_working_job" rake task in the rails app
237249 Then I should receive no requests
238250
239251@rails_integrations
240252Scenario : Using Que as the Active Job queue adapter for a job that works
241253 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "que"
242- And I run "WorkingJob.perform_later" with the rails runner
243- And I run "timeout 5 bundle exec que -q default ./config/environment.rb" in the rails app
254+ And I start the rails service with the database
255+ And I run "bundle exec que -q default ./config/environment.rb" in the rails app in the background
256+ When I run the "fixture:queue_working_job" rake task in the rails app
244257 Then I should receive no requests
245258
246259@rails_integrations
247260Scenario : Using Delayed Job as the Active Job queue adapter for a job that works
248261 Given I set environment variable "ACTIVE_JOB_QUEUE_ADAPTER" to "delayed_job"
249- And I run "WorkingJob.perform_later" with the rails runner
250- And I run the "jobs:workoff" rake task in the rails app
262+ And I start the rails service with the database
263+ And I run the "jobs:work" rake task in the rails app in the background
264+ When I run the "fixture:queue_working_job" rake task in the rails app
251265 Then I should receive no requests
0 commit comments