update-allow-list-reads-lock.test 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. --TEST--
  2. Limited update takes rules from lock if available, and not from the installed repo + composer.json
  3. --COMPOSER--
  4. {
  5. "repositories": [
  6. {
  7. "type": "package",
  8. "package": [
  9. { "name": "toupdate/installed", "version": "1.1.0" },
  10. { "name": "toupdate/installed", "version": "1.0.0" },
  11. { "name": "toupdate/notinstalled", "version": "1.1.0" },
  12. { "name": "toupdate/notinstalled", "version": "1.0.0" },
  13. { "name": "old/installed", "version": "0.9.0" },
  14. { "name": "old/installed", "version": "1.0.0" }
  15. ]
  16. }
  17. ],
  18. "require": {
  19. "toupdate/installed": "1.*",
  20. "toupdate/notinstalled": "1.*",
  21. "old/installed": "*"
  22. }
  23. }
  24. --LOCK--
  25. {
  26. "packages": [
  27. { "name": "old/installed", "version": "1.0.0" },
  28. { "name": "toupdate/installed", "version": "1.0.0" },
  29. { "name": "toupdate/notinstalled", "version": "1.0.0" }
  30. ],
  31. "packages-dev": [],
  32. "aliases": [],
  33. "minimum-stability": "stable",
  34. "stability-flags": [],
  35. "prefer-stable": false,
  36. "prefer-lowest": false
  37. }
  38. --INSTALLED--
  39. [
  40. { "name": "toupdate/installed", "version": "1.0.0" },
  41. { "name": "old/installed", "version": "0.9.0" }
  42. ]
  43. --RUN--
  44. update toupdate/installed
  45. --EXPECT--
  46. Upgrading old/installed (0.9.0 => 1.0.0)
  47. Upgrading toupdate/installed (1.0.0 => 1.1.0)
  48. Installing toupdate/notinstalled (1.0.0)