mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Add return types to tests (#10)
This commit is contained in:
parent
1321bfca36
commit
e9b60580f5
62 changed files with 153 additions and 155 deletions
|
@ -176,7 +176,7 @@ class RemoteFilesystemTest extends TestCase
|
|||
$fs = $this->getRemoteFilesystemWithMockedMethods(array('getRemoteContents'));
|
||||
|
||||
$fs->expects($this->once())->method('getRemoteContents')
|
||||
->willReturnCallback(function ($originUrl, $fileUrl, $ctx, &$http_response_header) {
|
||||
->willReturnCallback(function ($originUrl, $fileUrl, $ctx, &$http_response_header): string {
|
||||
$http_response_header = array('http/1.1 401 unauthorized');
|
||||
|
||||
return '';
|
||||
|
@ -313,7 +313,7 @@ class RemoteFilesystemTest extends TestCase
|
|||
$domains = array();
|
||||
$io
|
||||
->method('hasAuthentication')
|
||||
->willReturnCallback(function ($arg) use (&$domains) {
|
||||
->willReturnCallback(function ($arg) use (&$domains): bool {
|
||||
$domains[] = $arg;
|
||||
// first time is called with bitbucket.org, then it redirects to bbuseruploads.s3.amazonaws.com so next time we have no auth configured
|
||||
return $arg === 'bitbucket.org';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue