Skip to content

Commit d98ae6a

Browse files
authored
Merge pull request #21 from AzuraCast/update-dependencies
2 parents 8a9b787 + a505462 commit d98ae6a

37 files changed

+143
-140
lines changed

azuracast.env

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
1-
#
2-
# AzuraCast Customization
3-
#
4-
5-
APPLICATION_ENV=testing
6-
7-
INIT_BASE_URL=docker.local
8-
INIT_INSTANCE_NAME=local testing
9-
10-
INIT_ADMIN_USERNAME=[email protected]
11-
INIT_ADMIN_PASSWORD=2g4oXx6VKhmV423g2FRMHLwcIqI7F8cWqIpHlSORKAHl
12-
INIT_ADMIN_API_KEY=ef6528b921f46018:86292817776bd1a9083b9d9d9f71a6bd
13-
INIT_MUSIC_PATH=/var/azuracast/init_music
14-
15-
#
16-
# PHP API Client environment vars
17-
#
18-
19-
AZURACAST_HOST=http://web/
20-
AZURACAST_API_KEY=ef6528b921f46018:86292817776bd1a9083b9d9d9f71a6bd
21-
AZURACAST_STATION_ID=1
1+
#
2+
# AzuraCast Customization
3+
#
4+
5+
APPLICATION_ENV=testing
6+
7+
INIT_BASE_URL=docker.local
8+
INIT_INSTANCE_NAME=local testing
9+
10+
INIT_ADMIN_EMAIL=[email protected]
11+
INIT_ADMIN_PASSWORD=2g4oXx6VKhmV423g2FRMHLwcIqI7F8cWqIpHlSORKAHl
12+
INIT_ADMIN_API_KEY=ef6528b921f46018:86292817776bd1a9083b9d9d9f71a6bd
13+
INIT_MUSIC_PATH=/var/azuracast/init_music
14+
15+
#
16+
# PHP API Client environment vars
17+
#
18+
19+
AZURACAST_HOST=http://web/
20+
AZURACAST_API_KEY=ef6528b921f46018:86292817776bd1a9083b9d9d9f71a6bd
21+
AZURACAST_STATION_ID=1

composer.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,16 @@
2020
"ext-json": "*",
2121
"ext-gd": "*",
2222

23-
"guzzlehttp/guzzle": "^6.3"
23+
"guzzlehttp/guzzle": "^7.0"
2424
},
2525
"require-dev": {
2626
"fzaninotto/faker": "^1.8",
27-
"overtrue/phplint": "^1.1",
28-
"phpstan/phpstan": "^0.11.1",
29-
"phpstan/phpstan-strict-rules": "^0.11.0",
30-
"phpunit/phpunit": "^7.5",
27+
"overtrue/phplint": "^2.2",
28+
"phpstan/phpstan": "^0.12.54",
29+
"phpstan/phpstan-strict-rules": "^0.12.5",
30+
"phpunit/phpunit": "^9.4",
3131
"roave/security-advisories": "dev-master",
32-
"vlucas/phpdotenv": "^3.4"
32+
"vlucas/phpdotenv": "^5.2"
3333
},
3434
"autoload": {
3535
"psr-4": {

docker-compose.testing.yml

Lines changed: 22 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,22 @@
1-
# Travis CI Testing file
2-
# This file will be renamed docker-compose.override.yml
3-
# it will override a standard AzuraCast installation.
4-
5-
version: '2.2'
6-
7-
services:
8-
cli:
9-
image: azuracast/azuracast_testing:latest
10-
volumes:
11-
- ./:/app
12-
- composer_data:/tmp
13-
env_file: azuracast.env
14-
command: /bin/true
15-
web:
16-
volumes:
17-
- ./tests/resources/:/var/azuracast/init_music
18-
19-
volumes:
20-
composer_data: {}
1+
# Travis CI Testing file
2+
# This file will be renamed docker-compose.override.yml
3+
# it will override a standard AzuraCast installation.
4+
5+
version: '2.2'
6+
7+
services:
8+
cli:
9+
image: azuracast/azuracast_testing:latest
10+
volumes:
11+
- ./:/app
12+
- composer_data:/tmp
13+
env_file: azuracast.env
14+
networks:
15+
- frontend
16+
command: /bin/true
17+
web:
18+
volumes:
19+
- ./tests/resources/:/var/azuracast/init_music
20+
21+
volumes:
22+
composer_data: {}

src/AbstractClient.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
namespace AzuraCast\Api;
55

66
use GuzzleHttp\Client;
7-
use GuzzleHttp\Exception\GuzzleException;
87

98
abstract class AbstractClient
109
{
@@ -40,7 +39,7 @@ public function setHttpClient(Client $httpClient): AbstractClient
4039
/**
4140
* @param string $method
4241
* @param string $uri
43-
* @param array $options
42+
* @param mixed[] $options
4443
*
4544
* @return mixed
4645
*

src/AbstractStationClient.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
namespace AzuraCast\Api;
55

66
use GuzzleHttp\Client;
7-
use GuzzleHttp\Exception\GuzzleException;
87

98
abstract class AbstractStationClient extends AbstractClient
109
{

src/Admin/UsersClient.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55

66
use AzuraCast\Api\AbstractClient;
77
use AzuraCast\Api\Dto;
8+
use AzuraCast\Api\Dto\ApiKeyDto;
9+
use AzuraCast\Api\Dto\RoleDto;
810
use AzuraCast\Api\Exception;
911

1012
class UsersClient extends AbstractClient
@@ -50,8 +52,8 @@ public function get(int $userId): Dto\UserDto
5052
* @param string $name
5153
* @param string $locale
5254
* @param string $theme
53-
* @param array $roles
54-
* @param array $apiKeys
55+
* @param RoleDto[] $roles
56+
* @param ApiKeyDto[] $apiKeys
5557
*
5658
* @return Dto\UserDto
5759
*
@@ -97,8 +99,8 @@ public function create(
9799
* @param string $name
98100
* @param string $locale
99101
* @param string $theme
100-
* @param array $roles
101-
* @param array $apiKeys
102+
* @param RoleDto[] $roles
103+
* @param ApiKeyDto[] $apiKeys
102104
*
103105
* @return Dto\UserDto
104106
*

src/Dto/AdminRelayDto.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ public function jsonSerialize()
336336
}
337337

338338
/**
339-
* @param array $stationData
339+
* @param mixed[] $stationData
340340
*
341341
* @return AdminRelayDto
342342
*/

src/Dto/AdminRelayUpdateDto.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,15 @@ class AdminRelayUpdateDto implements \JsonSerializable
2121
protected $isVisibleOnPublicPages;
2222

2323
/**
24-
* @var array|null
24+
* @var mixed[]|null
2525
*/
2626
protected $nowplaying;
2727

2828
/**
2929
* @param string|null $baseUrl
3030
* @param string|null $name
3131
* @param bool|null $isVisibleOnPublicPages
32-
* @param array|null $nowplaying
32+
* @param mixed[]|null $nowplaying
3333
*/
3434
public function __construct(?string $baseUrl, ?string $name, ?bool $isVisibleOnPublicPages, ?array $nowplaying)
3535
{
@@ -100,15 +100,15 @@ public function setIsVisibleOnPublicPages(?bool $isVisibleOnPublicPages): AdminR
100100
}
101101

102102
/**
103-
* @return array|null
103+
* @return mixed[]|null
104104
*/
105105
public function getNowplaying(): ?array
106106
{
107107
return $this->nowplaying;
108108
}
109109

110110
/**
111-
* @param array|null $nowplaying
111+
* @param mixed[]|null $nowplaying
112112
*
113113
* @return AdminRelayUpdateDto
114114
*/

src/Dto/ApiKeyDto.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,8 @@ public function jsonSerialize()
7979
}
8080

8181
/**
82-
* @param array $apiKeyData
82+
* @param mixed[] $apiKeyData
83+
*
8384
* @return ApiKeyDto
8485
*/
8586
public static function fromArray(array $apiKeyData): self

src/Dto/CurrentSongDto.php

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class CurrentSongDto
3131
protected $duration;
3232

3333
/**
34-
* @var string
34+
* @var string|null
3535
*/
3636
protected $playlist;
3737

@@ -51,7 +51,7 @@ class CurrentSongDto
5151
* @param int $songHistoryId
5252
* @param int $playedAt
5353
* @param int $duration
54-
* @param string $playlist
54+
* @param string|null $playlist
5555
* @param bool $isRequest
5656
* @param SongDto $song
5757
*/
@@ -61,7 +61,7 @@ public function __construct(
6161
int $songHistoryId,
6262
int $playedAt,
6363
int $duration,
64-
string $playlist,
64+
?string $playlist,
6565
bool $isRequest,
6666
SongDto $song
6767
) {
@@ -176,19 +176,19 @@ public function setDuration(int $duration): CurrentSongDto
176176
}
177177

178178
/**
179-
* @return string
179+
* @return string|null
180180
*/
181-
public function getPlaylist(): string
181+
public function getPlaylist(): ?string
182182
{
183183
return $this->playlist;
184184
}
185185

186186
/**
187-
* @param string $playlist
187+
* @param string|null $playlist
188188
*
189189
* @return CurrentSongDto
190190
*/
191-
public function setPlaylist(string $playlist): CurrentSongDto
191+
public function setPlaylist(?string $playlist): CurrentSongDto
192192
{
193193
$this->playlist = $playlist;
194194

@@ -236,7 +236,8 @@ public function setSong(SongDto $song): CurrentSongDto
236236
}
237237

238238
/**
239-
* @param array $currentSongData
239+
* @param mixed[] $currentSongData
240+
*
240241
* @return CurrentSongDto
241242
*/
242243
public static function fromArray(array $currentSongData): self

0 commit comments

Comments
 (0)