composer update
This commit is contained in:
@@ -34,18 +34,6 @@ class FileLinkFormatterTest extends TestCase
|
||||
$this->assertSame("debug://open?url=file://$file&line=3", $sut->format($file, 3));
|
||||
}
|
||||
|
||||
public function testWhenFileLinkFormatAndRequest()
|
||||
{
|
||||
$file = __DIR__.\DIRECTORY_SEPARATOR.'file.php';
|
||||
$requestStack = new RequestStack();
|
||||
$request = new Request();
|
||||
$requestStack->push($request);
|
||||
|
||||
$sut = new FileLinkFormatter('debug://open?url=file://%f&line=%l', $requestStack, __DIR__, '/_profiler/open?file=%f&line=%l#line%l');
|
||||
|
||||
$this->assertSame("debug://open?url=file://$file&line=3", $sut->format($file, 3));
|
||||
}
|
||||
|
||||
public function testWhenNoFileLinkFormatAndRequest()
|
||||
{
|
||||
$file = __DIR__.\DIRECTORY_SEPARATOR.'file.php';
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
namespace Symfony\Component\HttpKernel\Tests\Debug;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Symfony\Component\EventDispatcher\Event;
|
||||
use Symfony\Component\EventDispatcher\EventDispatcher;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\RequestStack;
|
||||
@@ -89,10 +90,10 @@ class TraceableEventDispatcherTest extends TestCase
|
||||
$called2 = true;
|
||||
});
|
||||
});
|
||||
$dispatcher->dispatch('my-event');
|
||||
$dispatcher->dispatch(new Event(), 'my-event');
|
||||
$this->assertTrue($called1);
|
||||
$this->assertFalse($called2);
|
||||
$dispatcher->dispatch('my-event');
|
||||
$dispatcher->dispatch(new Event(), 'my-event');
|
||||
$this->assertTrue($called2);
|
||||
}
|
||||
|
||||
@@ -104,7 +105,7 @@ class TraceableEventDispatcherTest extends TestCase
|
||||
};
|
||||
$eventDispatcher->addListener('foo', $listener1);
|
||||
$eventDispatcher->addListener('foo', function () {});
|
||||
$eventDispatcher->dispatch('foo');
|
||||
$eventDispatcher->dispatch(new Event(), 'foo');
|
||||
|
||||
$this->assertCount(1, $eventDispatcher->getListeners('foo'), 'expected listener1 to be removed');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user