@@ -51,6 +51,8 @@ class ConsumersRunnerTest extends \PHPUnit\Framework\TestCase
51
51
*/
52
52
protected function setUp ()
53
53
{
54
+ require_once __DIR__ . '/../../_files/consumers_runner_functions_mocks.php ' ;
55
+
54
56
$ this ->phpExecutableFinderMock = $ this ->getMockBuilder (phpExecutableFinder::class)
55
57
->disableOriginalConstructor ()
56
58
->getMock ();
@@ -116,7 +118,7 @@ public function testRun(
116
118
$ isRunExpects
117
119
) {
118
120
$ consumerName = 'consumerName ' ;
119
- $ pidFilePath = 'consumerName.pid ' ;
121
+ $ pidFilePath = 'consumerName-myHostName .pid ' ;
120
122
121
123
$ this ->deploymentConfigMock ->expects ($ this ->exactly (3 ))
122
124
->method ('get ' )
@@ -164,7 +166,7 @@ public function runDataProvider()
164
166
'isRun ' => false ,
165
167
'php ' => '' ,
166
168
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
167
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=20000 ' ],
169
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=20000 ' ],
168
170
'allowedConsumers ' => [],
169
171
'shellBackgroundExpects ' => 1 ,
170
172
'isRunExpects ' => 1 ,
@@ -174,7 +176,7 @@ public function runDataProvider()
174
176
'isRun ' => false ,
175
177
'php ' => '' ,
176
178
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
177
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
179
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
178
180
'allowedConsumers ' => [],
179
181
'shellBackgroundExpects ' => 1 ,
180
182
'isRunExpects ' => 1 ,
@@ -184,7 +186,7 @@ public function runDataProvider()
184
186
'isRun ' => false ,
185
187
'php ' => '' ,
186
188
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
187
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
189
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
188
190
'allowedConsumers ' => ['someConsumer ' ],
189
191
'shellBackgroundExpects ' => 0 ,
190
192
'isRunExpects ' => 0 ,
@@ -194,7 +196,7 @@ public function runDataProvider()
194
196
'isRun ' => true ,
195
197
'php ' => '' ,
196
198
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
197
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
199
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
198
200
'allowedConsumers ' => ['someConsumer ' ],
199
201
'shellBackgroundExpects ' => 0 ,
200
202
'isRunExpects ' => 0 ,
@@ -204,7 +206,7 @@ public function runDataProvider()
204
206
'isRun ' => true ,
205
207
'php ' => '' ,
206
208
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
207
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
209
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
208
210
'allowedConsumers ' => [],
209
211
'shellBackgroundExpects ' => 0 ,
210
212
'isRunExpects ' => 1 ,
@@ -214,7 +216,7 @@ public function runDataProvider()
214
216
'isRun ' => true ,
215
217
'php ' => '' ,
216
218
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
217
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
219
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
218
220
'allowedConsumers ' => ['consumerName ' ],
219
221
'shellBackgroundExpects ' => 0 ,
220
222
'isRunExpects ' => 1 ,
@@ -224,7 +226,7 @@ public function runDataProvider()
224
226
'isRun ' => false ,
225
227
'php ' => '' ,
226
228
'command ' => 'php ' . BP . '/bin/magento queue:consumers:start %s %s %s ' ,
227
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' , '--max-messages=10000 ' ],
229
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' , '--max-messages=10000 ' ],
228
230
'allowedConsumers ' => ['consumerName ' ],
229
231
'shellBackgroundExpects ' => 1 ,
230
232
'isRunExpects ' => 1 ,
@@ -234,7 +236,7 @@ public function runDataProvider()
234
236
'isRun ' => false ,
235
237
'php ' => '/bin/php ' ,
236
238
'command ' => '/bin/php ' . BP . '/bin/magento queue:consumers:start %s %s ' ,
237
- 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName.pid ' ],
239
+ 'arguments ' => ['consumerName ' , '--pid-file-path=consumerName-myHostName .pid ' ],
238
240
'allowedConsumers ' => ['consumerName ' ],
239
241
'shellBackgroundExpects ' => 1 ,
240
242
'isRunExpects ' => 1 ,
0 commit comments