install-missing-alias-from-lock.test 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. --TEST--
  2. Installing an old alias that doesn't exist anymore from a lock is possible
  3. --COMPOSER--
  4. {
  5. "repositories": [
  6. {
  7. "type": "package",
  8. "package": [
  9. {
  10. "name": "a/a", "version": "dev-master",
  11. "extra": { "branch-alias": { "dev-master": "2.2.x-dev" } },
  12. "source": { "reference": "master", "type": "git", "url": "" }
  13. }
  14. ]
  15. }
  16. ],
  17. "require": {
  18. "a/a": "2.1.*"
  19. },
  20. "minimum-stability": "dev"
  21. }
  22. --LOCK--
  23. {
  24. "packages": [
  25. {
  26. "name": "a/a", "version": "dev-master", "version_normalized": "9999999-dev",
  27. "extra": { "branch-alias": { "dev-master": "2.1.x-dev" } },
  28. "source": { "reference": "oldmaster", "type": "git", "url": "" },
  29. "type": "library"
  30. }
  31. ],
  32. "packages-dev": [],
  33. "aliases": [],
  34. "minimum-stability": "dev",
  35. "stability-flags": [],
  36. "prefer-stable": false,
  37. "prefer-lowest": false
  38. }
  39. --RUN--
  40. install
  41. --EXPECT--
  42. Installing a/a (dev-master oldmaster)
  43. Marking a/a (2.1.x-dev oldmaster) as installed, alias of a/a (dev-master oldmaster)