Skip to content

Commit 4274956

Browse files
committed
Added psalm
1 parent 2aeda5f commit 4274956

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

Helper/ArrayHelper.php

+2
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ public static function without(array $array, ...$keys): array
3333
}
3434

3535
/**
36+
* @psalm-suppress InvalidArrayOffset
37+
*
3638
* @param string ...$keys
3739
*/
3840
public static function remove(array &$array, ...$keys): array

Tests/ManagerTest.php

+7-7
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@ protected function setUp(): void
3535
$this->adapter = \Mockery::mock(AdapterInterface::class);
3636
}
3737

38-
public function testConstruct()
38+
public function testConstruct(): void
3939
{
4040
$manager = new Manager($this->adapter);
4141

4242
$this->assertInstanceOf(Manager::class, $manager);
4343
}
4444

45-
public function testGetSecret()
45+
public function testGetSecret(): void
4646
{
4747
$secret = new Secret('foo', 'bar');
4848
$manager = new Manager($this->adapter);
@@ -56,7 +56,7 @@ public function testGetSecret()
5656
$this->assertEquals($secret, $result);
5757
}
5858

59-
public function testGetBadSecret()
59+
public function testGetBadSecret(): void
6060
{
6161
$this->expectException(SecretNotFoundException::class);
6262
$this->expectExceptionMessage('No secret was found with the key: "foo"');
@@ -71,7 +71,7 @@ public function testGetBadSecret()
7171
$manager->getSecret('foo');
7272
}
7373

74-
public function testPutSecret()
74+
public function testPutSecret(): void
7575
{
7676
$manager = new Manager($this->adapter);
7777
$secret = new Secret('foo', 'bar');
@@ -84,7 +84,7 @@ public function testPutSecret()
8484
$this->assertEquals($secret, $response);
8585
}
8686

87-
public function testDeleteSecretByKey()
87+
public function testDeleteSecretByKey(): void
8888
{
8989
$manager = new Manager($this->adapter);
9090
$secret = new Secret('foo', '');
@@ -101,7 +101,7 @@ public function testDeleteSecretByKey()
101101
$this->assertTrue(true);
102102
}
103103

104-
public function testDeleteSecret()
104+
public function testDeleteSecret(): void
105105
{
106106
$manager = new Manager($this->adapter);
107107
$secret = new Secret('foo', 'bar');
@@ -114,7 +114,7 @@ public function testDeleteSecret()
114114
$this->assertTrue(true);
115115
}
116116

117-
public function testGetAdapter()
117+
public function testGetAdapter(): void
118118
{
119119
$manager = new Manager($this->adapter);
120120

0 commit comments

Comments
 (0)