mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Stop relying on OS to find executables on Windows, and migrate most Process calls to array syntax (#12180)
Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>
This commit is contained in:
parent
5a75d32414
commit
3dc279cf66
45 changed files with 714 additions and 584 deletions
|
@ -303,18 +303,18 @@ class GitHubDriverTest extends TestCase
|
|||
|
||||
$process = $this->getProcessExecutorMock();
|
||||
$process->expects([
|
||||
['cmd' => 'git config github.accesstoken', 'return' => 1],
|
||||
'git clone --mirror -- '.ProcessExecutor::escape($repoSshUrl).' '.ProcessExecutor::escape($this->config->get('cache-vcs-dir').'/git-github.com-composer-packagist.git/'),
|
||||
['cmd' => ['git', 'config', 'github.accesstoken'], 'return' => 1],
|
||||
['git', 'clone', '--mirror', '--', $repoSshUrl, $this->config->get('cache-vcs-dir').'/git-github.com-composer-packagist.git/'],
|
||||
[
|
||||
'cmd' => 'git show-ref --tags --dereference',
|
||||
'cmd' => ['git', 'show-ref', '--tags', '--dereference'],
|
||||
'stdout' => $sha.' refs/tags/'.$identifier,
|
||||
],
|
||||
[
|
||||
'cmd' => 'git branch --no-color --no-abbrev -v',
|
||||
'cmd' => ['git', 'branch', '--no-color', '--no-abbrev', '-v'],
|
||||
'stdout' => ' test_master edf93f1fccaebd8764383dc12016d0a1a9672d89 Fix test & behavior',
|
||||
],
|
||||
[
|
||||
'cmd' => 'git branch --no-color',
|
||||
'cmd' => ['git', 'branch', '--no-color'],
|
||||
'stdout' => '* test_master',
|
||||
],
|
||||
], true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue