solver-problems.test 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. --TEST--
  2. Test the error output of solver problems.
  3. --COMPOSER--
  4. {
  5. "repositories": [
  6. {
  7. "type": "package",
  8. "package": [
  9. { "name": "unstable/package", "version": "2.0.0-alpha" },
  10. { "name": "unstable/package", "version": "1.0.0" },
  11. { "name": "requirer", "version": "1.0.0", "require": {"dependency": "1.0.0" } },
  12. { "name": "dependency", "version": "2.0.0" },
  13. { "name": "dependency", "version": "1.0.0" }
  14. ]
  15. }
  16. ],
  17. "require": {
  18. "unstable/package": "2.*",
  19. "bogus": "1.*",
  20. "requirer": "1.*",
  21. "dependency": "2.*"
  22. }
  23. }
  24. --RUN--
  25. install
  26. --EXPECT-EXIT-CODE--
  27. 2
  28. --EXPECT-OUTPUT--
  29. Loading composer repositories with package information
  30. Updating dependencies (including require-dev)
  31. Your requirements could not be resolved to an installable set of packages.
  32. Problem 1
  33. - The requested package unstable/package 2.* exists as unstable/package[1.0.0] but those are rejected by your constraint.
  34. Problem 2
  35. - The requested package bogus could not be found in any version, there may be a typo in the package name.
  36. Problem 3
  37. - Installation request for requirer 1.* -> satisfiable by requirer[1.0.0].
  38. - requirer 1.0.0 requires dependency 1.0.0 -> satisfiable by dependency[1.0.0] but these conflict with your requirements or minimum-stability
  39. Potential causes:
  40. - A typo in the package name
  41. - The package is not available in a stable-enough version according to your minimum-stability setting
  42. see <https://getcomposer.org/doc/04-schema.md#minimum-stability> for more details.
  43. Read <https://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.
  44. --EXPECT--