update-allow-list-warns-non-existing-patterns.test 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. --TEST--
  2. Verify that partial updates warn about using patterns in the argument which have no matches
  3. --COMPOSER--
  4. {
  5. "repositories": [
  6. {
  7. "type": "package",
  8. "package": [
  9. { "name": "a/a", "version": "1.0.0" },
  10. { "name": "b/b", "version": "1.0.0" },
  11. { "name": "b/b", "version": "1.1.0" }
  12. ]
  13. }
  14. ],
  15. "require": {
  16. "a/a": "~1.0",
  17. "b/b": "~1.0"
  18. }
  19. }
  20. --INSTALLED--
  21. [
  22. { "name": "a/a", "version": "1.0.0" },
  23. { "name": "b/b", "version": "1.0.0" }
  24. ]
  25. --LOCK--
  26. {
  27. "packages": [
  28. { "name": "a/a", "version": "1.0.0" },
  29. { "name": "b/b", "version": "1.0.0" }
  30. ],
  31. "packages-dev": [],
  32. "aliases": [],
  33. "minimum-stability": "dev",
  34. "stability-flags": [],
  35. "prefer-stable": false,
  36. "prefer-lowest": false,
  37. "platform": [],
  38. "platform-dev": []
  39. }
  40. --RUN--
  41. update b/b foo/bar baz/* --with-dependencies
  42. --EXPECT-OUTPUT--
  43. Loading composer repositories with package information
  44. Updating dependencies
  45. <warning>Package "foo/bar" listed for update is not locked.</warning>
  46. <warning>Pattern "baz/*" listed for update does not match any locked packages.</warning>
  47. Lock file operations: 0 installs, 1 update, 0 removals
  48. - Upgrading b/b (1.0.0 => 1.1.0)
  49. Writing lock file
  50. Installing dependencies from lock file (including require-dev)
  51. Package operations: 0 installs, 1 update, 0 removals
  52. Generating autoload files
  53. --EXPECT--
  54. Upgrading b/b (1.0.0 => 1.1.0)