Fix codestyle in build and tests (#20586)

This commit is contained in:
Maksim Spirkov
2025-10-10 23:04:09 +03:00
committed by GitHub
parent 8005113753
commit 909396074e
361 changed files with 1422 additions and 790 deletions

View File

@ -1,4 +1,5 @@
<?php
/**
* @link https://www.yiiframework.com/
* @copyright Copyright (c) 2008 Yii Software LLC
@ -294,8 +295,6 @@ class UrlManagerParseUrlTest extends TestCase
// TODO implement with hostinfo
public function testParseRESTRequest()
{
$request = new Request();
@ -393,7 +392,9 @@ class UrlManagerParseUrlTest extends TestCase
$this->assertCount(1, $manager->rules);
$firstRule = $manager->rules[0];
$this->assertInstanceOf('yii\web\UrlRuleInterface', $firstRule);
$this->assertCount(1, $this->getInaccessibleProperty($arrayCache, '_cache'),
$this->assertCount(
1,
$this->getInaccessibleProperty($arrayCache, '_cache'),
'Cache contains the only one record that represents initial built rules'
);
@ -405,7 +406,9 @@ class UrlManagerParseUrlTest extends TestCase
$this->assertCount(4, $manager->rules);
$this->assertSame($firstRule, $manager->rules[0]);
$this->assertCount(3, $this->getInaccessibleProperty($arrayCache, '_cache'),
$this->assertCount(
3,
$this->getInaccessibleProperty($arrayCache, '_cache'),
'The addRules() method was called twice, adding 3 new rules to the UrlManager, but we have only ' .
'two additional caches: one for each addRules() method call.'
);
@ -460,6 +463,5 @@ class UrlManagerParseUrlTest extends TestCase
$result = $manager->parseRequest($this->getRequest('users/somecontroller/someaction'));
$this->assertEquals(['site/index', ['url' => 'users/somecontroller/someaction']], $result);
}
}