From 636401bbebb02521b736074dc97f81f10a1d69df Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Thu, 5 May 2016 08:56:13 +0200 Subject: [PATCH] [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. --- .../Tests/Debug/TraceableEventDispatcherTest.php | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php index dd54e73b34..2dd8292a1b 100644 --- a/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php +++ b/src/Symfony/Component/EventDispatcher/Tests/Debug/TraceableEventDispatcherTest.php @@ -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();