[EventDispatcher] fix tests

The `getListenerPriority()` method was added to the event dispatcher
interface in Symfony 3.0. Thus, it no longer makes sense to have a test
that expects the method not to exist (the corresponding code in the
`TraceableEventDispatcher` was already removed in 576a55c.
This commit is contained in:
Christian Flothmann 2016-05-05 08:56:13 +02:00
parent 576a55c5d9
commit 636401bbeb

View File

@ -73,16 +73,6 @@ class TraceableEventDispatcherTest extends \PHPUnit_Framework_TestCase
$this->assertSame(123, $tdispatcher->getListenerPriority('foo', $listeners[0]));
}
public function testGetListenerPriorityReturnsZeroWhenWrappedMethodDoesNotExist()
{
$dispatcher = $this->getMock('Symfony\Component\EventDispatcher\EventDispatcherInterface');
$traceableEventDispatcher = new TraceableEventDispatcher($dispatcher, new Stopwatch());
$traceableEventDispatcher->addListener('foo', function () {}, 123);
$listeners = $traceableEventDispatcher->getListeners('foo');
$this->assertSame(0, $traceableEventDispatcher->getListenerPriority('foo', $listeners[0]));
}
public function testAddRemoveSubscriber()
{
$dispatcher = new EventDispatcher();