use PHPUnit\Framework\TestCase;
use Symfony\Component\PropertyAccess\Exception\NoSuchIndexException;
use Symfony\Component\PropertyAccess\PropertyAccess;
use Symfony\Component\PropertyAccess\PropertyAccessor;
abstract class PropertyAccessorArrayAccessTestCase extends TestCase
{ protected PropertyAccessor
$propertyAccessor;
protected function setUp(): void
{ $this->propertyAccessor =
new PropertyAccessor();
} abstract protected static function getContainer(array
$array);
public static function getValidPropertyPaths(): array
{ return [ [static::
getContainer(['firstName' => 'Bernhard'
]), '[firstName]', 'Bernhard'
],
[static::
getContainer(['person' =>
static::
getContainer(['firstName' => 'Bernhard'
])]), '[person][firstName]', 'Bernhard'
],
];
}