Commit fb0a1a34 authored by Anton Smirnov's avatar Anton Smirnov
Browse files

More updates

parent 1b6dfe5b
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -40,7 +40,7 @@
        "nikic/iter": "^2.0"
    },
    "require-dev": {
        "phpunit/phpunit": "^9.5",
        "phpunit/phpunit": "^10.5",
        "psy/psysh": "*",
        "sandfox.dev/code-standard": "^1.2025.06.29",
        "squizlabs/php_codesniffer": "*",
+1 −1
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@
    @see https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-Ruleset
-->
<ruleset name="Custom Standard" namespace="MyProject\CS\Standard">
    <rule ref="SandFox_PHP74"/>
    <rule ref="SandFox_PHP81"/>
    <file>src</file>
    <file>tests</file>
</ruleset>
+8 −4
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8" ?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         convertDeprecationsToExceptions="true"
         displayDetailsOnTestsThatTriggerErrors="true"
         displayDetailsOnTestsThatTriggerNotices="true"
         displayDetailsOnTestsThatTriggerWarnings="true"
         displayDetailsOnTestsThatTriggerDeprecations="true"
         displayDetailsOnPhpunitDeprecations="true"
         executionOrder="random"
         xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.5/phpunit.xsd">
         xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd">
    <testsuites>
        <testsuite name="all">
            <directory>tests</directory>
        </testsuite>
    </testsuites>
    <coverage>
    <source>
        <include>
            <directory>src</directory>
        </include>
    </coverage>
    </source>
    <php>
        <ini name="error_reporting" value="E_ALL"/>
    </php>
+1 −1
Original line number Diff line number Diff line
@@ -10,5 +10,5 @@ interface AbsolutePathInterface extends PathInterface
     * @param static $targetPath
     * @param callable|null $equals (string $a, string $b): bool
     */
    public function makeRelative(self $targetPath, ?callable $equals = null): RelativePathInterface;
    public function makeRelative(self $targetPath, callable|null $equals = null): RelativePathInterface;
}
+2 −2
Original line number Diff line number Diff line
@@ -23,9 +23,9 @@ abstract class AbstractAbsolutePath extends AbstractPath implements AbsolutePath
     * @param static $targetPath
     * @param callable|null $equals(string $a, string $b): bool
     */
    public function makeRelative(AbsolutePathInterface $targetPath, ?callable $equals = null): RelativePathInterface
    public function makeRelative(AbsolutePathInterface $targetPath, callable|null $equals = null): RelativePathInterface
    {
        if (\get_class($this) !== \get_class($targetPath) || $this->prefix !== $targetPath->prefix) {
        if ($this::class !== $targetPath::class || $this->prefix !== $targetPath->prefix) {
            throw new \InvalidArgumentException(
                'You can only make relative path from paths of same type and same prefix',
            );
Loading