> * more complex (two instances failover) > diff --git a/test/data/htools/hbal-desiredlocation-2.data > b/test/data/htools/hbal-desiredlocation-2.data > new file mode 100644 > index 0000000..a337535 > --- /dev/null > +++ b/test/data/htools/hbal-desiredlocation-2.data > @@ -0,0 +1,10 @@ > +group-01|fake-uuid-01|preferred|| > + > +node-01|16384|0|14236|409600|306600|16|N|fake-uuid-01|1|power:b > +node-02|16384|0|16384|409600|306600|16|N|fake-uuid-01|1|power:a > + > +inst1|1024|51200|1|running|Y|node-01|node-02|drbd|power:a|1 > +inst2|1024|51200|1|running|Y|node-01|node-02|drbd|power:b|1 > + > +htools:desiredlocation:power > +htools:nlocation:power
> +./test/hs/hbal --print-nodes=name,pcnt -t > $TESTDATA_DIR/hbal-desiredlocation-2.data > +>>>2/Final cluster status: > + Name pcnt > + node-01 1 > + node-02 1/ > +>>>= 0 Maybe I wasn't clear about this in my last review email. Just counting the number of instances per node in the final configuration cannot, in this example, distinguish between no changes and the correct path. However, when we write tests for a new feature, we write them in such a way that the test would fail had the feature not been implemented. Here, current hbal (without your changes) would not do anything also resulting in a situation with one instance running on each node, hence the test would pass as well. So you really do have to check "Solution length" or a similar indicator to make this test meaningful. Thanks, Klaus -- Klaus Aehlig Google Germany GmbH, Dienerstr. 12, 80331 Muenchen Registergericht und -nummer: Hamburg, HRB 86891 Sitz der Gesellschaft: Hamburg Geschaeftsfuehrer: Graham Law, Christine Elizabeth Flores
