Various tweaks 3.4
This commit is contained in:
parent
35b670112c
commit
47cb83a6ec
@ -960,7 +960,7 @@ class QuestionHelperTest extends AbstractQuestionHelperTest
|
||||
$dialog = new QuestionHelper();
|
||||
|
||||
$question = new Question('What\'s your name?');
|
||||
$question->setValidator(function () {
|
||||
$question->setValidator(function ($value) {
|
||||
if (!$value) {
|
||||
throw new \Exception('A value is required.');
|
||||
}
|
||||
|
@ -20,6 +20,7 @@ class InputDefinitionTest extends TestCase
|
||||
{
|
||||
protected static $fixtures;
|
||||
|
||||
protected $multi;
|
||||
protected $foo;
|
||||
protected $bar;
|
||||
protected $foo1;
|
||||
|
@ -196,7 +196,7 @@ class CommandTesterTest extends TestCase
|
||||
];
|
||||
|
||||
$command = new Command('foo');
|
||||
$command->setCode(function ($input, $output) use ($questions, $command) {
|
||||
$command->setCode(function ($input, $output) use ($questions) {
|
||||
$io = new SymfonyStyle($input, $output);
|
||||
$io->ask($questions[0]);
|
||||
$io->ask($questions[1]);
|
||||
|
@ -9,7 +9,7 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\Ldap\Tests;
|
||||
namespace Symfony\Component\Ldap\Tests\Adapter\ExtLdap;
|
||||
|
||||
use Symfony\Component\Ldap\Adapter\ExtLdap\Adapter;
|
||||
use Symfony\Component\Ldap\Adapter\ExtLdap\Collection;
|
||||
@ -17,6 +17,7 @@ use Symfony\Component\Ldap\Adapter\ExtLdap\Query;
|
||||
use Symfony\Component\Ldap\Entry;
|
||||
use Symfony\Component\Ldap\Exception\NotBoundException;
|
||||
use Symfony\Component\Ldap\LdapInterface;
|
||||
use Symfony\Component\Ldap\Tests\LdapTestCase;
|
||||
|
||||
/**
|
||||
* @requires extension ldap
|
||||
|
@ -9,13 +9,14 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\Ldap\Tests;
|
||||
namespace Symfony\Component\Ldap\Tests\Adapter\ExtLdap;
|
||||
|
||||
use Symfony\Component\Ldap\Adapter\ExtLdap\Adapter;
|
||||
use Symfony\Component\Ldap\Adapter\ExtLdap\Collection;
|
||||
use Symfony\Component\Ldap\Entry;
|
||||
use Symfony\Component\Ldap\Exception\LdapException;
|
||||
use Symfony\Component\Ldap\Exception\NotBoundException;
|
||||
use Symfony\Component\Ldap\Tests\LdapTestCase;
|
||||
|
||||
/**
|
||||
* @requires extension ldap
|
||||
|
@ -40,7 +40,7 @@ class PhpFileLoader extends FileLoader
|
||||
|
||||
// the closure forbids access to the private scope in the included file
|
||||
$loader = $this;
|
||||
$load = \Closure::bind(static function ($file) use ($loader) {
|
||||
$load = \Closure::bind(static function ($file) {
|
||||
return include $file;
|
||||
}, null, ProtectedPhpFileLoader::class);
|
||||
|
||||
|
@ -165,7 +165,7 @@ class CsrfTokenManagerTest extends TestCase
|
||||
$requestStack = new RequestStack();
|
||||
$requestStack->push(new Request([], [], [], [], [], ['HTTPS' => 'on']));
|
||||
|
||||
$manager = new CsrfTokenManager($generator, $storage, null, $requestStack);
|
||||
$manager = new CsrfTokenManager($generator, $storage);
|
||||
|
||||
$token = $manager->getToken('foo');
|
||||
$this->assertSame('foo', $token->getId());
|
||||
|
@ -9,7 +9,7 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\Security\Tests\Http\Firewall;
|
||||
namespace Symfony\Component\Security\Http\Tests\Firewall;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
|
@ -9,7 +9,7 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\Security\Tests\Http\Firewall;
|
||||
namespace Symfony\Component\Security\Http\Tests\Firewall;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
|
@ -37,11 +37,6 @@ class ProjectTemplateLoader4 extends Loader
|
||||
return $this->logger;
|
||||
}
|
||||
|
||||
public function getDebugger()
|
||||
{
|
||||
return $this->debugger;
|
||||
}
|
||||
|
||||
public function isFresh(TemplateReferenceInterface $template, $time)
|
||||
{
|
||||
return false;
|
||||
|
@ -93,7 +93,7 @@ class PhpEngineTest extends TestCase
|
||||
|
||||
public function testExtendRender()
|
||||
{
|
||||
$engine = new ProjectTemplateEngine(new TemplateNameParser(), $this->loader, [], [new SlotsHelper()]);
|
||||
$engine = new ProjectTemplateEngine(new TemplateNameParser(), $this->loader, []);
|
||||
try {
|
||||
$engine->render('name');
|
||||
$this->fail('->render() throws an InvalidArgumentException if the template does not exist');
|
||||
|
Reference in New Issue
Block a user