-
-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #548 from nikophil/fix/deprecation-layerr
fix(bc-layer): few improvments
- Loading branch information
Showing
13 changed files
with
170 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
...sts/ChangeFactoryBaseClass/Fixtures/change-factory-extending-user-defined-factory.php.inc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<?php | ||
|
||
namespace Zenstruck\Foundry\Utils\Rector\Tests\Fixtures; | ||
|
||
use Zenstruck\Foundry\Utils\Rector\Tests\Fixtures\DummyObject; | ||
use Zenstruck\Foundry\ModelFactory; | ||
use Zenstruck\Foundry\Proxy; | ||
|
||
final class DummyModelFactoryExtendingUserFactory extends DummyObjectModelFactory | ||
{ | ||
protected function getDefaults(): array | ||
{ | ||
return []; | ||
} | ||
|
||
protected function initialize(): self | ||
{ | ||
return $this; | ||
} | ||
|
||
protected static function getClass(): string | ||
{ | ||
return DummyObject::class; | ||
} | ||
} | ||
?> | ||
----- | ||
<?php | ||
|
||
namespace Zenstruck\Foundry\Utils\Rector\Tests\Fixtures; | ||
|
||
use Zenstruck\Foundry\Utils\Rector\Tests\Fixtures\DummyObject; | ||
use Zenstruck\Foundry\ModelFactory; | ||
use Zenstruck\Foundry\Proxy; | ||
|
||
final class DummyModelFactoryExtendingUserFactory extends DummyObjectModelFactory | ||
{ | ||
protected function defaults(): array | ||
{ | ||
return []; | ||
} | ||
|
||
protected function initialize(): static | ||
{ | ||
return $this; | ||
} | ||
|
||
public static function class(): string | ||
{ | ||
return DummyObject::class; | ||
} | ||
} | ||
?> |
53 changes: 53 additions & 0 deletions
53
...s/ChangeFactoryMethodCalls/Fixtures/change-factory-extending-user-defined-factory.php.inc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<?php | ||
|
||
namespace Zenstruck\Foundry\Utils\Rector\Tests\Fixtures; | ||
|
||
use Zenstruck\Foundry\Utils\Rector\Tests\Fixtures\DummyObject; | ||
use Zenstruck\Foundry\ModelFactory; | ||
use Zenstruck\Foundry\Proxy; | ||
|
||
final class DummyModelFactoryExtendingUserFactory extends DummyObjectModelFactory | ||
{ | ||
protected function getDefaults(): array | ||
{ | ||
return self::getDefaults(); | ||
} | ||
|
||
protected function initialize(): self | ||
{ | ||
return $this; | ||
} | ||
|
||
protected static function getClass(): string | ||
{ | ||
return DummyObject::class; | ||
} | ||
} | ||
?> | ||
----- | ||
<?php | ||
|
||
namespace Zenstruck\Foundry\Utils\Rector\Tests\Fixtures; | ||
|
||
use Zenstruck\Foundry\Utils\Rector\Tests\Fixtures\DummyObject; | ||
use Zenstruck\Foundry\ModelFactory; | ||
use Zenstruck\Foundry\Proxy; | ||
|
||
final class DummyModelFactoryExtendingUserFactory extends DummyObjectModelFactory | ||
{ | ||
protected function getDefaults(): array | ||
{ | ||
return self::defaults(); | ||
} | ||
|
||
protected function initialize(): self | ||
{ | ||
return $this; | ||
} | ||
|
||
protected static function getClass(): string | ||
{ | ||
return DummyObject::class; | ||
} | ||
} | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
utils/rector/tests/Fixtures/DummyModelFactoryExtendingUserFactory.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Zenstruck\Foundry\Utils\Rector\Tests\Fixtures; | ||
|
||
final class DummyModelFactoryExtendingUserFactory extends DummyObjectModelFactory | ||
{ | ||
protected function getDefaults(): array | ||
{ | ||
return []; | ||
} | ||
|
||
protected static function getClass(): string | ||
{ | ||
return DummyObject::class; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters