1
0
Fork 0

Fix tests to use default-branch prop

pull/8997/head
Jordi Boggiano 2020-06-19 15:35:09 +02:00
parent 6349764c2d
commit d19f5db568
No known key found for this signature in database
GPG Key ID: 7BBD42C429EC80BC
13 changed files with 100 additions and 58 deletions

View File

@ -6,8 +6,8 @@ Test the error output of solver problems with dev-master aliases.
{ {
"type": "package", "type": "package",
"package": [ "package": [
{"name": "a/a", "version": "dev-master", "require": {"d/d": "1.0.0"}}, {"name": "a/a", "version": "dev-master", "require": {"d/d": "1.0.0"}, "default-branch": true},
{"name": "b/b", "version": "dev-master", "require": {"d/d": "2.0.0"}}, {"name": "b/b", "version": "dev-master", "require": {"d/d": "2.0.0"}, "default-branch": true},
{"name": "d/d", "version": "1.0.0"}, {"name": "d/d", "version": "1.0.0"},
{"name": "d/d", "version": "2.0.0"} {"name": "d/d", "version": "2.0.0"}
] ]

View File

@ -6,7 +6,7 @@ Test the error output of solver problems with dev-master aliases.
{ {
"type": "package", "type": "package",
"package": [ "package": [
{ "name": "locked/pkg", "version": "dev-master", "require": {"locked/dependency": "1.0.0"} } { "name": "locked/pkg", "version": "dev-master", "require": {"locked/dependency": "1.0.0"}, "default-branch": true }
] ]
} }
], ],
@ -18,7 +18,7 @@ Test the error output of solver problems with dev-master aliases.
--LOCK-- --LOCK--
{ {
"packages": [ "packages": [
{ "name": "locked/pkg", "version": "dev-master", "require": {"locked/dependency": "1.0.0"} }, { "name": "locked/pkg", "version": "dev-master", "require": {"locked/dependency": "1.0.0"}, "default-branch": true },
{ "name": "locked/dependency", "version": "1.0.0" } { "name": "locked/dependency", "version": "1.0.0" }
], ],
"packages-dev": [], "packages-dev": [],

View File

@ -8,7 +8,8 @@ Aliases of referenced packages work
"package": [ "package": [
{ {
"name": "a/aliased", "version": "dev-master", "name": "a/aliased", "version": "dev-master",
"source": { "reference": "orig", "type": "git", "url": "" } "source": { "reference": "orig", "type": "git", "url": "" },
"default-branch": true
}, },
{ {
"name": "b/requirer", "version": "1.0.0", "name": "b/requirer", "version": "1.0.0",
@ -31,7 +32,8 @@ update
{ {
"name": "a/aliased", "version": "dev-master", "name": "a/aliased", "version": "dev-master",
"source": { "reference": "abcd", "type": "git", "url": "" }, "source": { "reference": "abcd", "type": "git", "url": "" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "b/requirer", "version": "1.0.0", "name": "b/requirer", "version": "1.0.0",

View File

@ -13,20 +13,24 @@ Aliases take precedence over default package even if default is selected
{ {
"name": "a/req", "version": "dev-master", "name": "a/req", "version": "dev-master",
"extra": { "branch-alias": { "dev-master": "1.0.x-dev" } }, "extra": { "branch-alias": { "dev-master": "1.0.x-dev" } },
"source": { "reference": "forked", "type": "git", "url": "" } "source": { "reference": "forked", "type": "git", "url": "" },
"default-branch": true
}, },
{ {
"name": "a/req", "version": "dev-master", "name": "a/req", "version": "dev-master",
"extra": { "branch-alias": { "dev-master": "1.0.x-dev" } }, "extra": { "branch-alias": { "dev-master": "1.0.x-dev" } },
"source": { "reference": "master", "type": "git", "url": "" } "source": { "reference": "master", "type": "git", "url": "" },
"default-branch": true
}, },
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"require": { "a/req": "dev-master" } "require": { "a/req": "dev-master" },
"default-branch": true
}, },
{ {
"name": "a/b", "version": "dev-master", "name": "a/b", "version": "dev-master",
"require": { "a/req": "dev-master" } "require": { "a/req": "dev-master" },
"default-branch": true
} }
] ]
} }
@ -44,12 +48,14 @@ Aliases take precedence over default package even if default is selected
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"require": { "a/req": "dev-master" }, "require": { "a/req": "dev-master" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "a/b", "version": "dev-master", "name": "a/b", "version": "dev-master",
"require": { "a/req": "dev-master" }, "require": { "a/req": "dev-master" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "a/req", "version": "dev-feature-foo", "name": "a/req", "version": "dev-feature-foo",

View File

@ -11,7 +11,8 @@ Installing double aliased package
"dist": { "type": "file", "url": "" }, "dist": { "type": "file", "url": "" },
"require": { "require": {
"b/b": "dev-master" "b/b": "dev-master"
} },
"default-branch": true
}, },
{ {
"name": "b/b", "version": "dev-foo", "name": "b/b", "version": "dev-foo",

View File

@ -14,7 +14,8 @@ Installs a dev package from lock using dist
"type": "zip", "type": "zip",
"url": "http://www.example.com/dist.zip", "url": "http://www.example.com/dist.zip",
"reference": "459720ff3b74ee0c0d159277c6f2f5df89d8a4f6" "reference": "459720ff3b74ee0c0d159277c6f2f5df89d8a4f6"
} },
"default-branch": true
} }
] ]
} }
@ -37,7 +38,8 @@ install --prefer-dist
"url": "http://www.example.com/dist.zip", "url": "http://www.example.com/dist.zip",
"reference": "459720ff3b74ee0c0d159277c6f2f5df89d8a4f6" "reference": "459720ff3b74ee0c0d159277c6f2f5df89d8a4f6"
}, },
"type": "library" "type": "library",
"default-branch": true
} }
], ],
"packages-dev": [], "packages-dev": [],

View File

@ -7,18 +7,19 @@ Installs a dev package forcing it's reference
"type": "package", "type": "package",
"package": [ "package": [
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-main",
"source": { "reference": "abc123", "url": "", "type": "git" } "source": { "reference": "abc123", "url": "", "type": "git" },
"default-branch": true
} }
] ]
} }
], ],
"require": { "require": {
"a/a": "dev-master#def000" "a/a": "dev-main#def000"
} }
} }
--RUN-- --RUN--
install install
--EXPECT-- --EXPECT--
Installing a/a (dev-master def000) Installing a/a (dev-main def000)
Marking a/a (9999999-dev def000) as installed, alias of a/a (dev-master def000) Marking a/a (9999999-dev def000) as installed, alias of a/a (dev-main def000)

View File

@ -7,7 +7,7 @@ Test that a conflict against >=5 does not include dev-master or other dev-x
"type": "package", "type": "package",
"package": [ "package": [
{ "name": "conflicter/pkg", "version": "1.0.0", "conflict": { "victim/pkg": ">=5", "victim/pkg2": ">=5" } }, { "name": "conflicter/pkg", "version": "1.0.0", "conflict": { "victim/pkg": ">=5", "victim/pkg2": ">=5" } },
{ "name": "victim/pkg", "version": "dev-master" }, { "name": "victim/pkg", "version": "dev-master", "default-branch": true },
{ "name": "victim/pkg2", "version": "dev-foo" } { "name": "victim/pkg2", "version": "dev-foo" }
] ]
} }

View File

@ -17,7 +17,8 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/a/newa", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/a/newa", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/a/newa/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" } "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/a/newa/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"default-branch": true
}, },
{ {
"name": "b/b", "version": "2.0.3", "name": "b/b", "version": "2.0.3",
@ -32,23 +33,27 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
{ {
"name": "d/d", "version": "dev-master", "name": "d/d", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/d/newd", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/d/newd", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/d/newd/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" } "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/d/newd/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"default-branch": true
}, },
{ {
"name": "e/e", "version": "dev-master", "name": "e/e", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/e/newe", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/e/newe", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/e/newe/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" } "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/e/newe/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"default-branch": true
}, },
{ {
"name": "f/f", "version": "dev-master", "name": "f/f", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/f/newf", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/f/newf", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/f/newf/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" }, "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/f/newf/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"transport-options": { "foo": "bar2" } "transport-options": { "foo": "bar2" },
"default-branch": true
}, },
{ {
"name": "g/g", "version": "dev-master", "name": "g/g", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/g/newg", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/g/newg", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/g/newg/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" } "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/g/newg/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"default-branch": true
} }
] ]
} }
@ -68,7 +73,8 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/a/a", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/a/a", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/a/a/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" } "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/a/a/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"default-branch": true
}, },
{ {
"name": "b/b", "version": "2.0.3", "name": "b/b", "version": "2.0.3",
@ -83,19 +89,22 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
{ {
"name": "d/d", "version": "dev-master", "name": "d/d", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/d", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/d", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/d/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" } "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/d/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"default-branch": true
}, },
{ {
"name": "f/f", "version": "dev-master", "name": "f/f", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"transport-options": { "foo": "bar" } "transport-options": { "foo": "bar" },
"default-branch": true
}, },
{ {
"name": "g/g", "version": "dev-master", "name": "g/g", "version": "dev-master",
"source": { "reference": "0000000000000000000000000000000000000000", "url": "https://github.com/g/g", "type": "git" }, "source": { "reference": "0000000000000000000000000000000000000000", "url": "https://github.com/g/g", "type": "git" },
"dist": { "reference": "0000000000000000000000000000000000000000", "url": "https://api.github.com/repos/g/g/zipball/0000000000000000000000000000000000000000", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "0000000000000000000000000000000000000000", "url": "https://api.github.com/repos/g/g/zipball/0000000000000000000000000000000000000000", "type": "zip", "shasum": "oldsum" },
"transport-options": { "foo": "bar" } "transport-options": { "foo": "bar" },
"default-branch": true
} }
] ]
--LOCK-- --LOCK--
@ -105,7 +114,8 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/a/a", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/a/a", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/a/a/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/a/a/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "b/b", "version": "2.0.3", "name": "b/b", "version": "2.0.3",
@ -123,21 +133,24 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
"name": "d/d", "version": "dev-master", "name": "d/d", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/d", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/d", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/d/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/d/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "f/f", "version": "dev-master", "name": "f/f", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"type": "library", "type": "library",
"transport-options": { "foo": "bar" } "transport-options": { "foo": "bar" },
"default-branch": true
}, },
{ {
"name": "g/g", "version": "dev-master", "name": "g/g", "version": "dev-master",
"source": { "reference": "0000000000000000000000000000000000000000", "url": "https://github.com/g/g", "type": "git" }, "source": { "reference": "0000000000000000000000000000000000000000", "url": "https://github.com/g/g", "type": "git" },
"dist": { "reference": "0000000000000000000000000000000000000000", "url": "https://api.github.com/repos/g/g/zipball/0000000000000000000000000000000000000000", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "0000000000000000000000000000000000000000", "url": "https://api.github.com/repos/g/g/zipball/0000000000000000000000000000000000000000", "type": "zip", "shasum": "oldsum" },
"type": "library", "type": "library",
"transport-options": { "foo": "bar" } "transport-options": { "foo": "bar" },
"default-branch": true
} }
], ],
"packages-dev": [], "packages-dev": [],
@ -156,7 +169,8 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/a/newa", "type": "git" }, "source": { "reference": "2222222222222222222222222222222222222222", "url": "https://github.com/a/newa", "type": "git" },
"dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/a/newa/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" }, "dist": { "reference": "2222222222222222222222222222222222222222", "url": "https://api.github.com/repos/a/newa/tarball/2222222222222222222222222222222222222222", "type": "tar", "shasum": "newsum" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "b/b", "version": "2.0.3", "name": "b/b", "version": "2.0.3",
@ -174,26 +188,30 @@ g/g is dev and installed in a different ref than the #ref, so it gets updated an
"name": "d/d", "version": "dev-master", "name": "d/d", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/newd", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/d/newd", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/newd/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/d/newd/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "e/e", "version": "dev-master", "name": "e/e", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/e/newe", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/e/newe", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/e/newe/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/e/newe/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" },
"type": "library" "type": "library",
"default-branch": true
}, },
{ {
"name": "f/f", "version": "dev-master", "name": "f/f", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/f/f", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/f/f/zipball/1111111111111111111111111111111111111111", "type": "zip", "shasum": "oldsum" },
"type": "library", "type": "library",
"transport-options": { "foo": "bar" } "transport-options": { "foo": "bar" },
"default-branch": true
}, },
{ {
"name": "g/g", "version": "dev-master", "name": "g/g", "version": "dev-master",
"source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/g/newg", "type": "git" }, "source": { "reference": "1111111111111111111111111111111111111111", "url": "https://github.com/g/newg", "type": "git" },
"dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/g/newg/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" }, "dist": { "reference": "1111111111111111111111111111111111111111", "url": "https://api.github.com/repos/g/newg/tarball/1111111111111111111111111111111111111111", "type": "tar", "shasum": "newsum" },
"type": "library" "type": "library",
"default-branch": true
} }
], ],
"packages-dev": [], "packages-dev": [],

View File

@ -7,36 +7,39 @@ Updating a dev package to its latest ref should pick up new dependencies
"type": "package", "type": "package",
"package": [ "package": [
{ {
"name": "a/devpackage", "version": "dev-master", "name": "a/devpackage", "version": "dev-main",
"source": { "reference": "newref", "url": "", "type": "git" }, "source": { "reference": "newref", "url": "", "type": "git" },
"require": { "require": {
"a/dependency": "*" "a/dependency": "*"
} },
"default-branch": true
}, },
{ {
"name": "a/dependency", "version": "dev-master", "name": "a/dependency", "version": "dev-main",
"source": { "reference": "ref", "url": "", "type": "git" }, "source": { "reference": "ref", "url": "", "type": "git" },
"require": {} "require": {},
"default-branch": true
} }
] ]
} }
], ],
"require": { "require": {
"a/devpackage": "dev-master" "a/devpackage": "dev-main"
}, },
"minimum-stability": "dev" "minimum-stability": "dev"
} }
--INSTALLED-- --INSTALLED--
[ [
{ {
"name": "a/devpackage", "version": "dev-master", "name": "a/devpackage", "version": "dev-main",
"source": { "reference": "oldref", "url": "", "type": "git" }, "source": { "reference": "oldref", "url": "", "type": "git" },
"require": {} "require": {},
"default-branch": true
} }
] ]
--RUN-- --RUN--
update update
--EXPECT-- --EXPECT--
Installing a/dependency (dev-master ref) Installing a/dependency (dev-main ref)
Marking a/dependency (9999999-dev ref) as installed, alias of a/dependency (dev-master ref) Marking a/dependency (9999999-dev ref) as installed, alias of a/dependency (dev-main ref)
Upgrading a/devpackage (dev-master oldref => dev-master newref) Upgrading a/devpackage (dev-main oldref => dev-main newref)

View File

@ -8,7 +8,8 @@ Downgrading from unstable to more stable package should work even if already ins
"package": [ "package": [
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "abcd", "url": "", "type": "git" } "source": { "reference": "abcd", "url": "", "type": "git" },
"default-branch": true
}, },
{ {
"name": "a/a", "version": "1.0.0", "name": "a/a", "version": "1.0.0",
@ -17,7 +18,8 @@ Downgrading from unstable to more stable package should work even if already ins
}, },
{ {
"name": "b/b", "version": "dev-master", "name": "b/b", "version": "dev-master",
"source": { "reference": "abcd", "url": "", "type": "git" } "source": { "reference": "abcd", "url": "", "type": "git" },
"default-branch": true
}, },
{ {
"name": "b/b", "version": "1.0.0", "name": "b/b", "version": "1.0.0",
@ -36,11 +38,13 @@ Downgrading from unstable to more stable package should work even if already ins
[ [
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "abcd", "url": "", "type": "git" } "source": { "reference": "abcd", "url": "", "type": "git" },
"default-branch": true
}, },
{ {
"name": "b/b", "version": "dev-master", "name": "b/b", "version": "dev-master",
"source": { "reference": "abcd", "url": "", "type": "git" } "source": { "reference": "abcd", "url": "", "type": "git" },
"default-branch": true
} }
] ]
--RUN-- --RUN--

View File

@ -8,7 +8,8 @@ Update to a state without dependency works well from locked with dependency
[ [
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "1234", "type": "git", "url": "" } "source": { "reference": "1234", "type": "git", "url": "" },
"default-branch": true
} }
] ]
--LOCK-- --LOCK--
@ -17,7 +18,8 @@ Update to a state without dependency works well from locked with dependency
{ {
"name": "a/a", "version": "dev-master", "name": "a/a", "version": "dev-master",
"source": { "reference": "1234", "type": "git", "url": "" }, "source": { "reference": "1234", "type": "git", "url": "" },
"type": "library" "type": "library",
"default-branch": true
} }
], ],
"packages-dev": [], "packages-dev": [],

View File

@ -13,7 +13,8 @@ Installing locked dev packages should remove old dependencies
{ {
"name": "a/devpackage", "version": "dev-master", "name": "a/devpackage", "version": "dev-master",
"source": { "reference": "newref", "url": "", "type": "git" }, "source": { "reference": "newref", "url": "", "type": "git" },
"require": {} "require": {},
"default-branch": true
} }
], ],
"packages-dev": [], "packages-dev": [],
@ -30,12 +31,14 @@ Installing locked dev packages should remove old dependencies
"source": { "reference": "oldref", "url": "", "type": "git" }, "source": { "reference": "oldref", "url": "", "type": "git" },
"require": { "require": {
"a/dependency": "*" "a/dependency": "*"
} },
"default-branch": true
}, },
{ {
"name": "a/dependency", "version": "dev-master", "name": "a/dependency", "version": "dev-master",
"source": { "reference": "ref", "url": "", "type": "git" }, "source": { "reference": "ref", "url": "", "type": "git" },
"require": {} "require": {},
"default-branch": true
} }
] ]
--RUN-- --RUN--