1
0
Fork 0
Commit Graph

9589 Commits (8e2dd62d10b85a3a2de198b5dd100a73e604c4b5)

Author SHA1 Message Date
Michael Chekin c23670c3ec
Add Util\AuthHelper unit test coverage (#8863)
* Add AuthHelper::addAuthenticationHeader() test on missing authentication credentials.

* Add AuthHelper::addAuthenticationHeader() test on bearer password.

* Add AuthHelper::addAuthenticationHeader() test on Github token.

* Add AuthHelper::addAuthenticationHeader() test on Gitlab Oauth token.

* Add $authenticationDisplayMessage write expectation to AuthHelper::addAuthenticationHeader() tests.

* Add AuthHelper::addAuthenticationHeader() test on Gitlab private token.

* Add AuthHelper::addAuthenticationHeader() test on Bitbucket Oauth token.

* Add AuthHelper::addAuthenticationHeader() test on Bitbucket public urls.

* Add AuthHelper::addAuthenticationHeader() test on Basic Http Authentication.

* Add AuthHelper::isPublicBitBucketDownload() tests.

* Rename AuthHelperTest $credentials variable to $auth.

* Add AuthHelper::storeAuth() test for auto-store option.

* Add AuthHelper::storeAuth() test for user prompt and y(es) answer.

* Add AuthHelper::storeAuth() test for user prompt and n(o) answer.

* Add AuthHelper::storeAuth() test for user prompt with invalid answer.

* Add AuthHelper::promptAuthIfNeeded() test for Github authentication failure.

- add GitHub hard dependency mock (new GitHub(...) mock)

* Run AuthHelper::promptAuthIfNeeded() tests only with PHP > 5.3

* Run AuthHelper::promptAuthIfNeeded() tests only with PHP >= 5.4

* Run AuthHelper::promptAuthIfNeeded() tests only with PHP 5.4

* Exclude PHPStan analyses of '../tests/Composer/Test/Util/Mocks/*'

* Exclude AuthHelper::promptAuthIfNeeded() tests from current pull request.

* Extract repetitive AuthHelperTest authentication expectation into a method.
2020-05-04 09:48:23 +02:00
Jordi Boggiano c39391323d
Merge pull request #8865 from Ayesh/regex-improvements
Regex improvements with unnecessary `.*` matchers
2020-05-04 09:37:52 +02:00
Ayesh Karunaratne aa20413990
Improve regex in \Composer\Downloader\SvnDownloader::getCommitLogs() by removing unnecessary greedy operator 2020-05-04 01:03:15 +07:00
Ayesh Karunaratne d4c8478df5
Improve regex in \Composer\Repository\ComposerRepository::fetchFile() by removing unnecessary greedy operator 2020-05-04 00:38:53 +07:00
Helmut Hummel 7c891701e6 Fix package sorting
PackageSorter weighs the importance of a package
by counting how many times it is required by other packages.
This works by calculating the weight for each package name.

However currently the package index of the package array
is currently passed the weigh function, which basically
disables package sorting.

The reason for that is, that a package repository previously
returned the package list as associative array with  package name as keys,
but currently just as an array with integer keys.

Therefore we must extract the package name from the package
before passing it to the weigh function.
2020-05-03 16:31:47 +02:00
Jordi Boggiano 1d077ede70
Merge branch '1.10' 2020-05-01 18:08:22 +02:00
Jordi Boggiano bfe71fb952
Fix support for --self --name-only, fixes #8844 2020-05-01 18:03:22 +02:00
Jordi Boggiano 4ce3836f51
Fix creation of a php: dir when running create-project, fixes #8849 2020-05-01 17:23:32 +02:00
Jordi Boggiano 7f308d986e
Add --with to update command to allow downgrading to a specific version/applying custom temporary constraints, fixes #8756 2020-05-01 16:56:17 +02:00
Jordi Boggiano 3a64acb53e
Make sure versions are ordered also in the satisfied by package lists 2020-05-01 15:54:01 +02:00
Jordi Boggiano 56a11b9c2c
Deduplicate require/conflict rules which are the same but for different versions of the same package, fixes #8851 2020-05-01 15:41:54 +02:00
Jordi Boggiano fc8be2bed8
Add --no-dev to recommended check-platform-reqs command for prod deploy 2020-05-01 14:50:55 +02:00
Jordi Boggiano 54d8cbe5f8
Merge pull request #8855 from naderman/document-update-mirrors-lock-nothing
Documentation: Clarify composer update mirrors/nothing/lock
2020-05-01 14:46:54 +02:00
Jordi Boggiano 56811b4c8f
Exclude platform require/provides from InstalledVersions as concrete ones are also not listed 2020-05-01 13:10:50 +02:00
Jordi Boggiano 0071bc1ec0
Add docs about new runtime features 2020-05-01 10:18:54 +02:00
Jordi Boggiano 557fb873ee
Add a way to retrieve the Loop instance from Composer to be able to wait on promises to integrate things 2020-05-01 09:54:41 +02:00
Jordi Boggiano 3c593b0d12
Remove duplicate use statement 2020-04-30 21:36:17 +02:00
Jordi Boggiano 74a63b4d6b
Merge branch '1.10' 2020-04-30 21:31:29 +02:00
Jordi Boggiano 3c2889672b
Merge pull request #8847 from Jean85/add-composer-runtime-api
Add composer-runtime-api version constant
2020-04-30 21:30:13 +02:00
Jordi Boggiano 81bf47ffa2
Use fully qualified calls in hot classes 2020-04-30 21:28:05 +02:00
Nils Adermann 1cb6bbe550 Clarify composer update mirrors/nothing/lock
Addresses https://github.com/composer/composer/issues/7459 by listing these special arguments in the documentation.
2020-04-30 19:54:04 +02:00
Jordi Boggiano 00e1deec90
Annotate phpstan errors in pull requests (#8852)
Utilizing https://github.com/staabm/annotate-pull-request-from-checkstyle
2020-04-30 15:22:33 +02:00
Jordi Boggiano 11cd3e0a28
Update lock file 2020-04-30 15:21:55 +02:00
Jordi Boggiano a5f86a494e
Add a conflict on latest phpunit-bridge 2020-04-30 15:19:18 +02:00
Markus Staab 3c1757575e
Annotate phpstan errors in pull requests
Utilizing https://github.com/staabm/annotate-pull-request-from-checkstyle
2020-04-30 09:44:22 +02:00
Alessandro Lai ff05150c4e Add composer-runtime-api version constant 2020-04-29 09:02:51 +02:00
Basil Peace 6140897d08 feat: add archive.name config option 2020-04-29 01:01:48 +03:00
Alessandro Lai 270c7c3262
Backport validation support for composer-runtime-api (#8842)
Fixes #8841
2020-04-28 16:04:00 +02:00
Nils Adermann 56edd53046 Remove unnecessary implementation of interface method in abstract class 2020-04-28 11:57:03 +02:00
Michael Chekin b9be78b689
Additional Util\Bitbucket class test coverage (#8835) 2020-04-28 11:45:30 +02:00
Jordi Boggiano a63913c245
Merge pull request #8836 from kbacia7/master
close #8784, Added --locked option to composer show command. Displaying locked packages with --all option
2020-04-28 08:54:16 +02:00
Jordi Boggiano 6e7d7097e8
Add flag to docs 2020-04-28 08:53:23 +02:00
Kamil Bacia 0779308076
close #8784, Added --locked option to composer show command. Displaying locked packages with --all option 2020-04-27 21:53:12 +02:00
Nils Adermann 994a5b41c2
Provide default impl for abstract method in interface for PHP < 5.3.9 (#8837) 2020-04-26 09:15:15 +02:00
Jordi Boggiano d173af2d7a
Fix check-platform-reqs command to take into account provide/replace from the root package 2020-04-24 13:46:18 +02:00
Jordi Boggiano 6a6ea6057f
Handle provider/replacer packages and avoid checking extensions which are provided by packages, refs #8546 2020-04-24 13:38:50 +02:00
Jordi Boggiano d494df61ff
Make sure platform-check returns a non-0 exit code if it fails 2020-04-24 13:25:13 +02:00
Jordi Boggiano f34ec13253
Upadte changelog/upgrade to latest master state 2020-04-24 11:11:32 +02:00
Jordi Boggiano d89342dc43
Fix tests 2020-04-24 09:07:32 +02:00
Jordi Boggiano 755a73baa9
Only check for pcntl on cli SAPI, fixes #8828 2020-04-23 20:44:14 +02:00
Jordi Boggiano df0cada93f
Add test for #8669 2020-04-23 15:11:21 +02:00
PirxDanford 3a7ea25289
Introduce --no-install option for the update, require and remove commands
Closes #8669, fixes #8551

Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>
2020-04-23 14:55:07 +02:00
effulgentsia 46efcefefa
Added --json and --merge options to ConfigCommand (#8779) 2020-04-23 14:27:14 +02:00
Jordi Boggiano 1d4185b844
Recommend ocramius/package-versions fork if needed to solve dependencies 2020-04-23 13:51:57 +02:00
Jordi Boggiano 34801239f1
Tweak problem wording slightly 2020-04-23 13:17:34 +02:00
Jordi Boggiano d8678fc8f2
Update CONTRIBUTING.md 2020-04-23 11:14:42 +02:00
Jordi Boggiano b67dd2e201
Add coc file to appease the github UI 2020-04-23 11:14:08 +02:00
Carsten Brandt 8f8840bfda
Update 04-schema.md to reflect package naming in 2.0 (#8777) 2020-04-23 11:02:50 +02:00
Jordi Boggiano cdc6a87e8d
Fix docblock 2020-04-23 11:01:44 +02:00
Jordi Boggiano 9b8694bc0b
Show suggestions from root package in suggest, and lists them in count only on first install of a project, fixes #8805 2020-04-23 10:53:24 +02:00