Closed oliviercailloux closed 6 years ago
All tests works now.
Great job.
AlternativesComparisonBuilder
for clearer code and less duplication of code. Follow the example in getExampleAll
. Please make sure the order is always the same (currently in example 10 it’s w, x, y and in 13 it’s x, y, w).//
on the same line (e.g. // IVT example
), hard to read, unconventional and generally not well formatted automatically; use javadoc instead. In this case I think you can just remove these comments as the methods that give the output make it clear which is which.exampleALL added, I merge the code and modified all generate example as in exampleALL.
Create a class
io.github.oliviercailloux.decision.arguer.labreuche.Examples
with public static factory methods that return each aLabreucheModel
, namedgetExample5()
,getExample6()
, etc. The code of these methods is moved fromMainLabreucheModel
(which can be deleted afterwards).Also add
getExample5Output()
, etc., which return the right output (expected from the example).In the tests, ensure that the output returned by the model is correct, not only that it returns the right anchor. To do this it will be clearer to write one test method per example (
testExample5()
, …) inLabreucheModelTest
.In the tests, it is not useful to test each time that only one anchor is applicable: test it once, then for the other ones check simply the returned anchor, then check that the output is correct.