update-with-all-dependencies.test 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. --TEST--
  2. See Github issue #6661 ( github.com/composer/composer/issues/6661 ).
  3. When `--with-all-dependencies` is used, Composer\Installer::whitelistUpdateDependencies should update the dependencies of all whitelisted packages, even if the dependency is a root requirement.
  4. --COMPOSER--
  5. {
  6. "repositories": [
  7. {
  8. "type": "package",
  9. "package": [
  10. { "name": "a/a", "version": "1.0.0" },
  11. { "name": "a/a", "version": "1.1.0" },
  12. { "name": "b/b", "version": "1.0.0", "require": { "a/a": "~1.0" } },
  13. { "name": "b/b", "version": "1.1.0", "require": { "a/a": "~1.1" } }
  14. ]
  15. }
  16. ],
  17. "require": {
  18. "a/a": "~1.0",
  19. "b/b": "~1.0"
  20. }
  21. }
  22. --INSTALLED--
  23. [
  24. { "name": "a/a", "version": "1.0.0" },
  25. { "name": "b/b", "version": "1.0.0", "require": { "a/a": "~1.0" } }
  26. ]
  27. --RUN--
  28. update b/b --with-all-dependencies
  29. --EXPECT-OUTPUT--
  30. Loading composer repositories with package information
  31. Updating dependencies (including require-dev)
  32. Package operations: 0 installs, 2 updates, 0 removals
  33. Writing lock file
  34. Generating autoload files
  35. --EXPECT--
  36. Updating a/a (1.0.0) to a/a (1.1.0)
  37. Updating b/b (1.0.0) to b/b (1.1.0)