Jordi Boggiano
6573fd3f77
Add hint in solver exceptions as to what may be wrong
2012-07-04 15:57:51 +02:00
Jordi Boggiano
175d1939b5
Fix tests
2012-07-04 14:28:15 +02:00
Jordi Boggiano
e6f7150196
Change default minimum-stability to "stable", fixes #744
2012-07-04 14:22:09 +02:00
Jordi Boggiano
4fcc114f97
Merge pull request #808 from palex-fpt/not-equal-operator
...
Add '<>' operator to Version Parser
2012-06-22 07:00:18 -07:00
Nils Adermann
cc7632489d
Make problem report messages more readable
...
Added pretty strings to constraints
2012-06-20 19:06:36 +02:00
Alexey Prilipko
e130386612
Add '<>' operator for Version Parser
2012-06-19 12:11:11 +11:00
Grégoire Pineau
f4e9dd4fb8
Fixed PSR rules
2012-06-14 12:10:01 +02:00
Nils Adermann
a08c2a0b9f
Corrected altered error message in test
2012-06-07 11:07:09 +02:00
Nils Adermann
67fde90666
Correctly sort operations within transactions using DFS
...
Fixes #655
2012-06-05 01:06:35 +02:00
Nils Adermann
a7f1605cdf
Add test for correct sorting when force installing deps
2012-06-04 23:30:55 +02:00
Nils Adermann
26e051cb76
Decisions are now encapsulated in a separate object
2012-06-04 23:19:32 +02:00
Nils Adermann
c869566868
Make ruleHash a protected member of rules
2012-05-20 15:57:38 +02:00
Nils Adermann
dd527a4049
Remove weak rules
...
Since we no longer have suggest/recommend rules and no longer use any update
or feature rules so packages are removed by default, we do not need weak rules
anymore.
2012-05-19 21:49:48 +02:00
Nils Adermann
451bab1c2c
Get rid of Literal object / literal id mix, use literals only to save memory
2012-05-19 20:38:56 +02:00
Jordi Boggiano
453b9a616b
Add test for Pool handling and refactor a couple things
2012-05-11 17:21:02 +02:00
Nils Adermann
0c1944a9d0
Let the solver handle aliases instead of the installer
2012-05-09 15:15:39 +02:00
Nils Adermann
15f43571b9
Rules of type feature are no longer needed
2012-05-08 19:26:50 +02:00
Nils Adermann
c37e126e14
Installed packages are now always removed unless otherwise requested
...
This means that an update request must always be accompanied by an install
request, otherwise the package might be removed rather than updated.
2012-05-08 19:25:58 +02:00
Nils Adermann
5daeacf0ac
We won't implement choice rules, you need to edit composer.json to choose
2012-05-08 19:25:38 +02:00
Jordi Boggiano
f7440076fa
Revert "Merge remote-tracking branch 'naderman/remove-packages-by-default'"
...
This reverts commit 2988152602
, reversing
changes made to adb4188e12
.
2012-04-29 22:21:58 +02:00
Nils Adermann
f4d5568937
Rules of type feature are no longer needed
2012-04-27 18:28:51 +02:00
Nils Adermann
2cb2cde096
Installed packages are now always removed unless otherwise requested
...
This means that an update request must always be accompanied by an install
request, otherwise the package might be removed rather than updated.
2012-04-27 18:13:37 +02:00
Nils Adermann
0e537b9c93
We won't implement choice rules, you need to edit composer.json to choose
2012-04-27 17:46:13 +02:00
Jordi Boggiano
06fb1b8083
Fix priority of aliases when mixing root package aliases with branch-alias ones, fixes #576
2012-04-20 22:10:58 +02:00
Nils Adermann
a16aa68c1d
Rule literals are sorted, so first literal added is not first retrieved
...
Fixes #477
2012-04-01 22:26:44 +02:00
Nils Adermann
2c87fe5a22
Collect solver problems in Problem objects with human readable output.
2012-03-18 20:41:10 +01:00
Martin Hasoň
2b08df5192
Changed repository priority in the pool
2012-03-06 11:17:23 +01:00
Nils Adermann
f3ff53b17c
Create problems directly, rather than generating impossible rules
2012-02-20 12:58:27 +01:00
Nils Adermann
dd443cd570
Complete circular dependency with alternatives through virtual packages test
2012-02-19 20:08:15 +01:00
Nils Adermann
3e1749fbad
Readd update-all jobs and make them available through the request
2012-02-19 16:59:04 +01:00
Nils Adermann
9b8e62396c
Merge pull request #324 from edorian/installNonExistingPackage
...
Create an 'impossible rule' when installing non existent packages
2012-02-19 07:05:21 -08:00
Nils Adermann
3b06a22e69
Add getVersionConstraint test case to avoid version normalization issues
2012-02-19 15:58:19 +01:00
Volker Dusch
f304a0f129
Clean up the incomplete marker like suggested in https://github.com/composer/composer/pull/324#r465391
2012-02-19 15:38:03 +01:00
Nils Adermann
1ee5d99405
When changing watched literals of a rule, update the parent's next pointer
...
The previous rule was not previously updated to point to the next rule when
removing a middle rule from the watch tree for a literal. This resulted in
jumping from one literal's watch tree to another's, which could then jump
back to the original and cause infinite loop in a case like #265 .
Fixes #265
2012-02-19 15:35:13 +01:00
Volker Dusch
e20a79ac61
Fix TODO tags to confirm with the projects standard
2012-02-19 15:30:53 +01:00
Volker Dusch
eafe13d5a5
Create an impossible rule when trying to install something that doesn't exist.
...
The rule isn't acted upon yet (hence the incomplete test) but it is there as a reminder that this case needs to be handled.
2012-02-19 14:55:14 +01:00
Nils Adermann
e6143d1584
Add todos to explain why try/catch is inside the test
2012-02-19 00:21:39 +01:00
Nils Adermann
52d876e11e
Add SolverProblemsException and test basic solver failures
2012-02-19 00:15:23 +01:00
Volker Dusch
3fb75faa75
Now that no more update rules are created the code that handles them can be removed too.
...
Also adapted the tests that used TYPE_UPDATE exemplarily to use TYPE_FEATURE.
2012-02-18 19:19:49 +01:00
Volker Dusch
a8b2db64d5
Expaned the update tests to make sure a) Only requested updates execute and b) Installed repos with no actions get pruned from the jobqueue
2012-02-18 16:55:45 +01:00
Nils Adermann
8aa0127de8
Remove test of undefined behaviour for unknown types in rulesets
2012-02-18 13:09:19 +01:00
Nils Adermann
7609f27052
Merge branch 'add-tests' of https://github.com/l3l0/composer into new-master
...
* 'add-tests' of https://github.com/l3l0/composer :
Made fixes after review.
Made changes which fied warnings and errors in tests.
Fixed tests after update and merge of changes from upstream/master
Fixed code. Changes improved code testability
Added and extended some unit tests
2012-02-18 13:08:20 +01:00
Nils Adermann
460822fb96
Fix indentation of doc comment
2012-02-18 12:37:45 +01:00
Nils Adermann
3b54316e91
Add a test for the off by one error in solver conflict resolution
2012-02-18 12:33:55 +01:00
Leszek Prabucki
f59ca1e2f8
Made fixes after review.
2012-01-24 18:48:42 +01:00
Leszek Prabucki
de7f666118
Added and extended some unit tests
2012-01-24 18:44:54 +01:00
Jordi Boggiano
098ba8e583
Add test
2012-01-15 14:15:53 +01:00
Jordi Boggiano
8cfbf9e198
Fix update, fixes #125
2011-12-24 14:15:10 +01:00
Nils Adermann
a0faa4f69f
Add a test for the complex conflict resolution fixed in #118
2011-11-25 23:35:58 +01:00
Jordi Boggiano
8e6f8ae57e
Add prettyVersion to packages, fixes #76
2011-11-20 15:06:12 +01:00
Nils Adermann
4140f08d9c
Use a map of installed package ids in the solver
...
The assumption package.repo == installed no longer holds for installed
packages because there are multiple wrapped installed repositories.
2011-11-19 00:27:35 +01:00
Nils Adermann
e16c3f0626
Remove useless test, packages providing different versions aren't alternatives
2011-10-22 17:26:42 +02:00
Nils Adermann
0801d8ed31
Enable solver test regarding replaced packages after policy fix
2011-10-22 17:23:23 +02:00
Nils Adermann
571c14adf9
Prefer original packages over replaced packages of same repository priority
2011-10-22 17:20:45 +02:00
Nils Adermann
1b6f57e651
Correctly implement priorities and version numbers in the default policy
2011-10-22 16:44:10 +02:00
Nils Adermann
55d5e55195
DefaultPolicy test: pick package providing newest virtual package version
2011-10-21 15:22:47 +02:00
Nils Adermann
0c30610fdc
Complete the policy tests with provider and replacement tests
2011-10-21 14:58:31 +02:00
Nils Adermann
e4c94dd415
Adding tests for the default policy specifying its desired behaviour
2011-10-21 14:44:24 +02:00
Jordi Boggiano
40cc5fea1d
Add a few solver tests regarding "replace"
2011-10-15 20:04:29 +02:00
Nils Adermann
30f6c05069
Add test for choices in circular requirements and delete packagist based test
2011-09-25 23:50:54 +02:00
Nils Adermann
85f88de59d
Add a solver test for provided virtual packages and circular dependencies
2011-09-25 23:46:24 +02:00
everzet
123f5fef77
Refactored Operations in order to fulfill naderman requests
2011-09-25 14:40:12 +03:00
Jordi Boggiano
6d667a849e
Remove broken functional test
2011-09-24 17:00:18 +02:00
everzet
0a1e7320b0
Refactored solver result array. Now it returns array of operation objects which are much nicer to work with
2011-09-24 02:29:22 +03:00
Nils Adermann
b1d16a88b7
Test a replace link with a null constraint between packages
2011-08-21 07:08:34 -04:00
Nils Adermann
69ebbf0eac
Correct handling of rules with more than 2 literals.
2011-08-21 06:30:06 -04:00
Nils Adermann
db18e1b560
Add a few proper tests for literals, all tests passing now
2011-08-20 23:15:12 -04:00
Nils Adermann
ac61c3973b
Add a test for two equivalent installable packages and fix the functional test
2011-08-20 23:05:11 -04:00
Nils Adermann
0f6fb9b692
Separate transaction generation from solving and properly identify updates
2011-08-20 18:38:31 -04:00
Nils Adermann
f46aa495da
Turn obsolete relationships and replaced packages into conflict rules
2011-08-20 18:19:47 -04:00
Nils Adermann
ad25618bdd
Add install job and update rule conflict handling and reenable installation
2011-08-19 06:15:51 -04:00
Nils Adermann
1125de6bf2
Added disablePolicyRules to solve conflicts between remove jobs & update rules
...
This temporarily breaks installation of packages
2011-08-19 06:06:00 -04:00
Nils Adermann
01945c20f9
Simplify testSolverWithComposerRepo reusing utility methods from other tests
2011-08-05 04:17:07 -04:00
Nils Adermann
172c8b908e
Split the large solver test up into individual units testing smaller parts
2011-08-05 04:14:11 -04:00
Jordi Boggiano
b277b8e73c
Add failing test with composer repo
2011-07-21 13:42:47 +02:00
Jordi Boggiano
2d1f8fbe70
LiteralTest is incomplete
2011-07-21 12:16:24 +02:00
Nils Adermann
825deff09f
Completed analysis of unsolvable situations and main decision process
2011-07-08 07:11:04 -04:00
Nils Adermann
bc672deb32
Moving rule iteration logic to a separate RuleSet and RuleSetIterator class
2011-06-27 00:11:57 +02:00
Nils Adermann
498125adbe
Assertions are now properly decided before running the main solver.
...
Updating does not work yet. The test case works fine for installing/removing
the correct packages however. Weak (update/feature) rules are entirely ignored
so far.
Watches are on literal ids rather than literals to save on function calls
and memory usage. So a few methods for literals now have an id counter part.
This should probably be refactored to have the literal versions call the
id ones instead.
2011-06-07 22:43:26 +02:00
Jordi Boggiano
d181e32000
Fixed test expectation
2011-05-23 02:23:21 +02:00
Jordi Boggiano
00260a89ae
Make test fail
2011-05-23 02:18:11 +02:00
Jordi Boggiano
c6321e7277
Fix tests and invalid use statements
2011-04-17 23:45:37 +02:00
Jordi Boggiano
7ea2fd6c93
Fix author/copyright
2011-04-17 21:39:53 +02:00
Nils Adermann
933cc6179b
Import initial partial port of the libzypp satsolver.
2011-04-05 17:37:19 +02:00