Code Duplication    Length = 18-19 lines in 2 locations

Test/Case/Console/Command/SeederShellTest.php 2 locations

@@ 308-325 (lines=18) @@
305
	 * @return void
306
	 * @covers ::main
307
	 */
308
	public function testMainExecuteSeederGivenByParameter() {
309
		$this->_createShellMock(
310
			array('out', '_executeSeederTask')
311
		);
312
313
		$this->_shell->args[0] = 'Apple';
314
		$this->_shell->params['no-truncate'] = 'foo';
315
316
		$this->_shell->expects($this->at(0))->method('out')->with(
317
			$this->equalTo('Execute Apple seeder...')
318
		);
319
		$this->_shell->expects($this->at(1))->method('_executeSeederTask')->with(
320
			$this->equalTo("Apple"),
321
			$this->_shell->params['no-truncate']
322
		);
323
324
		$this->_shell->main();
325
	}
326
327
	/**
328
	 * Test the main method when executing a seeder given by parameter when there are seeders defined
@@ 335-353 (lines=19) @@
332
	 * @return void
333
	 * @covers ::main
334
	 */
335
	public function testMainExecuteSeederGivenByParameterWithDefinedSeeders() {
336
		$this->_createShellMock(
337
			array('out', '_executeSeederTask'),
338
			'SeederShellWithTasks'
339
		);
340
341
		$this->_shell->args[0] = 'Apple';
342
		$this->_shell->params['no-truncate'] = 'foo';
343
344
		$this->_shell->expects($this->at(0))->method('out')->with(
345
			$this->equalTo('Execute Apple seeder...')
346
		);
347
		$this->_shell->expects($this->at(1))->method('_executeSeederTask')->with(
348
			$this->equalTo("Apple"),
349
			$this->_shell->params['no-truncate']
350
		);
351
352
		$this->_shell->main();
353
	}
354
355
	/**
356
	 * Test the _executeSeederTask method when trying to execute an existing seeder