mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-23 04:14:36 +02:00
Fixed some more inspection issues
This commit is contained in:
parent
de96aae9a5
commit
29d1d49aca
83 changed files with 153 additions and 172 deletions
|
@ -31,8 +31,8 @@ use Symfony\Component\Security\Core\Exception\AccessDeniedException;
|
|||
*/
|
||||
abstract class AbstractAdminControllerTest extends WebTestCase
|
||||
{
|
||||
protected static $base_path = 'not_valid';
|
||||
protected static $entity_class = 'not valid';
|
||||
protected static string $base_path = 'not_valid';
|
||||
protected static string $entity_class = 'not valid';
|
||||
|
||||
public function readDataProvider(): array
|
||||
{
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Attachments\AttachmentType;
|
|||
*/
|
||||
class AttachmentTypeControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/attachment_type';
|
||||
protected static $entity_class = AttachmentType::class;
|
||||
protected static string $base_path = '/en'.'/attachment_type';
|
||||
protected static string $entity_class = AttachmentType::class;
|
||||
}
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\Category;
|
|||
*/
|
||||
class CategoryControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/category';
|
||||
protected static $entity_class = Category::class;
|
||||
protected static string $base_path = '/en'.'/category';
|
||||
protected static string $entity_class = Category::class;
|
||||
}
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\Footprint;
|
|||
*/
|
||||
class FootprintControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/footprint';
|
||||
protected static $entity_class = Footprint::class;
|
||||
protected static string $base_path = '/en'.'/footprint';
|
||||
protected static string $entity_class = Footprint::class;
|
||||
}
|
||||
|
|
|
@ -46,8 +46,8 @@ use Symfony\Component\Security\Core\Exception\AccessDeniedException;
|
|||
|
||||
class LabelProfileControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/label_profile';
|
||||
protected static $entity_class = LabelProfile::class;
|
||||
protected static string $base_path = '/en'.'/label_profile';
|
||||
protected static string $entity_class = LabelProfile::class;
|
||||
|
||||
/**
|
||||
* Tests if deleting an entity is working.
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\Manufacturer;
|
|||
*/
|
||||
class ManufacturerControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/manufacturer';
|
||||
protected static $entity_class = Manufacturer::class;
|
||||
protected static string $base_path = '/en'.'/manufacturer';
|
||||
protected static string $entity_class = Manufacturer::class;
|
||||
}
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\MeasurementUnit;
|
|||
*/
|
||||
class MeasurementUnitControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/measurement_unit';
|
||||
protected static $entity_class = MeasurementUnit::class;
|
||||
protected static string $base_path = '/en'.'/measurement_unit';
|
||||
protected static string $entity_class = MeasurementUnit::class;
|
||||
}
|
||||
|
|
|
@ -31,6 +31,6 @@ use App\Entity\ProjectSystem\Project;
|
|||
*/
|
||||
class ProjectControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/project';
|
||||
protected static $entity_class = Project::class;
|
||||
protected static string $base_path = '/en'.'/project';
|
||||
protected static string $entity_class = Project::class;
|
||||
}
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\Storelocation;
|
|||
*/
|
||||
class StorelocationControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/store_location';
|
||||
protected static $entity_class = Storelocation::class;
|
||||
protected static string $base_path = '/en'.'/store_location';
|
||||
protected static string $entity_class = Storelocation::class;
|
||||
}
|
||||
|
|
|
@ -30,6 +30,6 @@ use App\Entity\Parts\Supplier;
|
|||
*/
|
||||
class SupplierControllerTest extends AbstractAdminControllerTest
|
||||
{
|
||||
protected static $base_path = '/en'.'/supplier';
|
||||
protected static $entity_class = Supplier::class;
|
||||
protected static string $base_path = '/en'.'/supplier';
|
||||
protected static string $entity_class = Supplier::class;
|
||||
}
|
||||
|
|
|
@ -23,6 +23,7 @@ declare(strict_types=1);
|
|||
namespace App\Tests\Controller;
|
||||
|
||||
use App\Entity\UserSystem\User;
|
||||
use App\Repository\UserRepository;
|
||||
use Doctrine\ORM\EntityManagerInterface;
|
||||
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
||||
|
||||
|
@ -32,9 +33,9 @@ use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
|
|||
*/
|
||||
class RedirectControllerTest extends WebTestCase
|
||||
{
|
||||
protected $em;
|
||||
protected $userRepo;
|
||||
protected $client;
|
||||
protected EntityManagerInterface $em;
|
||||
protected UserRepository $userRepo;
|
||||
protected \Symfony\Bundle\FrameworkBundle\KernelBrowser $client;
|
||||
|
||||
protected function setUp(): void
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue