Fix indenting
parent
b51cfce8e6
commit
369e8a2247
|
@ -1,17 +1,26 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This file is part of Composer.
|
||||||
|
*
|
||||||
|
* (c) Nils Adermann <naderman@naderman.de>
|
||||||
|
* Jordi Boggiano <j.boggiano@seld.be>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE
|
||||||
|
* file that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
namespace Composer\Test\Script;
|
namespace Composer\Test\Script;
|
||||||
|
|
||||||
|
|
||||||
use Composer\Composer;
|
use Composer\Composer;
|
||||||
use Composer\Config;
|
use Composer\Config;
|
||||||
use Composer\Script\Event;
|
use Composer\Script\Event;
|
||||||
use Composer\Test\TestCase;
|
use Composer\Test\TestCase;
|
||||||
|
|
||||||
class EventTest extends TestCase {
|
class EventTest extends TestCase
|
||||||
|
{
|
||||||
public function testEventSetsOriginatingEvent() {
|
public function testEventSetsOriginatingEvent()
|
||||||
|
{
|
||||||
$io = $this->getMockBuilder('Composer\IO\IOInterface')->getMock();
|
$io = $this->getMockBuilder('Composer\IO\IOInterface')->getMock();
|
||||||
$composer = $this->createComposerInstance();
|
$composer = $this->createComposerInstance();
|
||||||
|
|
||||||
|
@ -31,14 +40,13 @@ class EventTest extends TestCase {
|
||||||
$scriptEvent->getOriginatingEvent(),
|
$scriptEvent->getOriginatingEvent(),
|
||||||
'getOriginatingEvent() SHOULD return test event'
|
'getOriginatingEvent() SHOULD return test event'
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function testEventCalculatesNestedOriginatingEvent() {
|
public function testEventCalculatesNestedOriginatingEvent()
|
||||||
|
{
|
||||||
$io = $this->getMockBuilder('Composer\IO\IOInterface')->getMock();
|
$io = $this->getMockBuilder('Composer\IO\IOInterface')->getMock();
|
||||||
$composer = $this->createComposerInstance();
|
$composer = $this->createComposerInstance();
|
||||||
|
|
||||||
|
|
||||||
$originatingEvent = new \Composer\EventDispatcher\Event('upperOriginatingEvent');
|
$originatingEvent = new \Composer\EventDispatcher\Event('upperOriginatingEvent');
|
||||||
$intermediateEvent = new Event('intermediate', $composer, $io, true);
|
$intermediateEvent = new Event('intermediate', $composer, $io, true);
|
||||||
$intermediateEvent->setOriginatingEvent($originatingEvent);
|
$intermediateEvent->setOriginatingEvent($originatingEvent);
|
||||||
|
@ -57,7 +65,6 @@ class EventTest extends TestCase {
|
||||||
$scriptEvent->getOriginatingEvent(),
|
$scriptEvent->getOriginatingEvent(),
|
||||||
'getOriginatingEvent() SHOULD return upper-most event'
|
'getOriginatingEvent() SHOULD return upper-most event'
|
||||||
);
|
);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private function createComposerInstance()
|
private function createComposerInstance()
|
||||||
|
|
Loading…
Reference in New Issue