-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into simplify-spec-usage
* develop: remove remnants of phpunit use builtin memory assertion use builtin method to disable memory limit update changelog fix constructor use named constructors
- Loading branch information
Showing
50 changed files
with
178 additions
and
169 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
/composer.lock | ||
/vendor | ||
/.phpunit.result.cache | ||
/.phpunit.cache | ||
/.cache | ||
/tmp |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,7 +29,7 @@ use Formal\AccessLayer\{ | |
use Innmind\Url\Url; | ||
use Innmind\Immutable\Sequence; | ||
|
||
$connection = new Lazy(static fn() => PDO::of(Url::of('mysql://user:[email protected]:3306/database_name'))); | ||
$connection = Lazy::of(static fn() => PDO::of(Url::of('mysql://user:[email protected]:3306/database_name'))); | ||
|
||
$rows = $connection(SQL::of('SELECT * FROM `some_table`')); | ||
$rows; // instanceof Sequence<Row> | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ use Formal\AccessLayer\{ | |
}; | ||
use Innmind\Url\Url; | ||
|
||
$connection = new Lazy( | ||
$connection = Lazy::of( | ||
static fn() => PDO::of( | ||
Url::of('mysql://user:[email protected]:3306/database_name'), | ||
), | ||
|
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
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -12,7 +12,7 @@ | |
|
||
return static function() { | ||
$port = \getenv('DB_PORT') ?: '3306'; | ||
$connection = new Lazy( | ||
$connection = Lazy::of( | ||
static fn() => PDO::of(Url::of("mysql://root:[email protected]:$port/example")), | ||
); | ||
Properties::seed($connection); | ||
|
@@ -32,7 +32,7 @@ | |
yield test( | ||
'Lazy connection must not be established at instanciation', | ||
static fn($assert) => $assert | ||
->object(new Lazy(static fn() => PDO::of(Url::of('mysql://unknown:[email protected]:3306/unknown')))) | ||
->object(Lazy::of(static fn() => PDO::of(Url::of('mysql://unknown:[email protected]:3306/unknown')))) | ||
->instance(Connection::class), | ||
); | ||
|
||
|
Oops, something went wrong.