Skip to content

Commit 0535163

Browse files
committed
Fix ci action runs
Signed-off-by: Joey Smith <jsmith@webinertia.net>
1 parent ebbb32b commit 0535163

8 files changed

Lines changed: 27 additions & 21 deletions

phpstan-baseline.neon

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
parameters:
22
ignoreErrors:
3+
-
4+
message: '#^PHPDoc tag @throws with type PhpDb\\Adapter\\Exception\\InvalidConnectionParametersException\|PhpDb\\Adapter\\Pgsql\\Exception\\ContainerException is not subtype of Throwable$#'
5+
identifier: throws.notThrowable
6+
count: 1
7+
path: src/Container/ConnectionInterfaceFactory.php
8+
39
-
410
message: '#^Parameter \#2 \$array of function implode expects array\<string\>, array\<int, array\<int\|string, string\>\> given\.$#'
511
identifier: argument.type

src/ConfigProvider.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
use PhpDb\Adapter\Driver\Pdo\Statement as PdoStatement;
1111
use PhpDb\Adapter\Driver\PdoConnectionInterface;
1212
use PhpDb\Adapter\Driver\PdoDriverInterface;
13-
use PhpDb\Pgsql\Pdo\Connection as PdoConnection;
14-
use PhpDb\Pgsql\Pdo\Driver as PdoDriver;
1513
use PhpDb\Adapter\Platform\PlatformInterface;
1614
use PhpDb\ConfigProvider as PhpDbConfigProvider;
1715
use PhpDb\Metadata\MetadataInterface;
16+
use PhpDb\Pgsql\Pdo\Connection as PdoConnection;
17+
use PhpDb\Pgsql\Pdo\Driver as PdoDriver;
1818

1919
/**
2020
* @internal

src/Container/ConnectionInterfaceFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
use PhpDb\Adapter\Driver\ConnectionInterface;
88
use PhpDb\Adapter\Exception\InvalidConnectionParametersException;
9-
use PhpDb\Pgsql\Connection;
109
use PhpDb\Adapter\Pgsql\Exception\ContainerException;
10+
use PhpDb\Pgsql\Connection;
1111
use Psr\Container\ContainerInterface;
1212

1313
use function is_array;

src/Container/DriverInterfaceFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
use Laminas\ServiceManager\ServiceManager;
88
use PhpDb\Adapter\Driver\DriverInterface;
9-
use PhpDb\Pgsql;
109
use PhpDb\Exception\ContainerException;
10+
use PhpDb\Pgsql;
1111
use Psr\Container\ContainerInterface;
1212

1313
final class DriverInterfaceFactory

src/Container/PlatformInterfaceFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44

55
namespace PhpDb\Pgsql\Container;
66

7-
use PhpDb\Pgsql;
87
use PhpDb\Adapter\Platform\PlatformInterface;
98
use PhpDb\Exception\ContainerException;
9+
use PhpDb\Pgsql;
1010
use Psr\Container\ContainerInterface;
1111

1212
final class PlatformInterfaceFactory

test/asset/SetupTrait.php

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
use PhpDb\Adapter\Driver\DriverInterface;
1212
use PhpDb\Adapter\Driver\PdoConnectionInterface;
1313
use PhpDb\Adapter\Driver\PdoDriverInterface;
14-
use PhpDb\Pgsql;
1514
use PhpDb\Adapter\Platform\PlatformInterface;
1615
use PhpDb\ConfigProvider as PhpDbConfigProvider;
16+
use PhpDb\Pgsql;
1717
use Psr\Container\ContainerInterface;
1818

1919
use function getenv;
@@ -27,11 +27,11 @@ trait SetupTrait
2727
protected function setUp(): void
2828
{
2929
$conn = [
30-
'host' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_HOSTNAME'),
30+
'host' => (string) getenv('TESTS_PHPDB_PGSQL_HOSTNAME'),
3131
'port' => 5432,
32-
'username' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_USERNAME'),
33-
'password' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_PASSWORD'),
34-
'database' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_DATABASE'),
32+
'username' => (string) getenv('TESTS_PHPDB_PGSQL_USERNAME'),
33+
'password' => (string) getenv('TESTS_PHPDB_PGSQL_PASSWORD'),
34+
'database' => (string) getenv('TESTS_PHPDB_PGSQL_DATABASE'),
3535
];
3636
$this->conn = $conn;
3737
parent::setUp();
@@ -87,21 +87,21 @@ public function getMockedAdapter(string $adapter = self::NATIVE_ADAPTER): Adapte
8787
self::NATIVE_ADAPTER => [
8888
'driver' => Pgsql\Driver::class,
8989
'connection' => [
90-
'host' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_HOSTNAME'),
90+
'host' => (string) getenv('TESTS_PHPDB_PGSQL_HOSTNAME'),
9191
'port' => 5432,
92-
'username' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_USERNAME'),
93-
'password' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_PASSWORD'),
94-
'database' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_DATABASE'),
92+
'username' => (string) getenv('TESTS_PHPDB_PGSQL_USERNAME'),
93+
'password' => (string) getenv('TESTS_PHPDB_PGSQL_PASSWORD'),
94+
'database' => (string) getenv('TESTS_PHPDB_PGSQL_DATABASE'),
9595
],
9696
],
9797
self::PDO_ADAPTER => [
9898
'driver' => Pgsql\Pdo\Driver::class,
9999
'connection' => [
100-
'host' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_HOSTNAME'),
100+
'host' => (string) getenv('TESTS_PHPDB_PGSQL_HOSTNAME'),
101101
'port' => 5432,
102-
'username' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_USERNAME'),
103-
'password' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_PASSWORD'),
104-
'database' => (string) getenv('TESTS_PHPDB_ADAPTER_PGSQL_DATABASE'),
102+
'username' => (string) getenv('TESTS_PHPDB_PGSQL_USERNAME'),
103+
'password' => (string) getenv('TESTS_PHPDB_PGSQL_PASSWORD'),
104+
'database' => (string) getenv('TESTS_PHPDB_PGSQL_DATABASE'),
105105
],
106106
],
107107
],

test/unit/Adapter/ConfigProviderTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99
use PhpDb\Adapter\Driver\Pdo\Statement as PdoStatement;
1010
use PhpDb\Adapter\Driver\PdoConnectionInterface;
1111
use PhpDb\Adapter\Driver\PdoDriverInterface;
12+
use PhpDb\Adapter\Platform\PlatformInterface;
13+
use PhpDb\Metadata\MetadataInterface;
1214
use PhpDb\Pgsql;
1315
use PhpDb\Pgsql\Pdo\Connection as PdoConnection;
1416
use PhpDb\Pgsql\Pdo\Driver as PdoDriver;
15-
use PhpDb\Adapter\Platform\PlatformInterface;
16-
use PhpDb\Metadata\MetadataInterface;
1717
use PHPUnit\Framework\Attributes\CoversMethod;
1818
use PHPUnit\Framework\Attributes\Depends;
1919
use PHPUnit\Framework\TestCase;

test/unit/Adapter/SetupTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public function testAdapterAbstractFactoryBuildsNativeDriver(): void
2222

2323
public function testAdapterInterfaceFactoryBuildsNativeDriver(): void
2424
{
25-
$adapter = $this->getAdapter(AdapterInterface::class);
25+
$adapter = $this->getAdapter(self::NATIVE_ADAPTER);
2626
self::assertInstanceOf(AdapterInterface::class, $adapter);
2727
}
2828
}

0 commit comments

Comments
 (0)