1
0
Fork 0

Add test checking references update to latest and remove TODO

pull/8561/head
Jordi Boggiano 2020-01-28 16:01:17 +01:00
parent 41720e9b70
commit 3f48acf56a
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
2 changed files with 31 additions and 3 deletions

View File

@ -388,9 +388,6 @@ class Installer
$pool = $repositorySet->createPool($request); $pool = $repositorySet->createPool($request);
// TODO ensure that the solver always picks most recent reference for dev packages, so they get updated even when just a new commit is pushed but version is unchanged
// should already be solved by using the remote package in all cases in the pool
// solve dependencies // solve dependencies
$solver = new Solver($policy, $pool, $this->io); $solver = new Solver($policy, $pool, $this->io);
try { try {

View File

@ -0,0 +1,31 @@
--TEST--
Updating a dev package should update to the latest available reference
--COMPOSER--
{
"repositories": [
{
"type": "package",
"package": [
{
"name": "a/a", "version": "dev-master",
"source": { "reference": "abc123", "url": "", "type": "git" }
}
]
}
],
"require": {
"a/a": "dev-master"
}
}
--INSTALLED--
[
{
"name": "a/a", "version": "dev-master",
"source": { "reference": "def000", "url": "", "type": "git" },
"dist": { "reference": "def000", "url": "", "type": "zip", "shasum": "" }
}
]
--RUN--
update
--EXPECT--
Updating a/a (dev-master def000 => dev-master abc123)