Browse Source

PrismCL: In test mode, don't immediately exit for not supported engine / solver combinations

In test mode, we'd like to have proper 'not supported' handling during the tests,
so we don't exit immediately when encountering an engine / iteration method that
is incompatible, as that would count as a failure.
master
Joachim Klein 8 years ago
parent
commit
bb6fc9a564
  1. 6
      prism/src/prism/PrismCL.java

6
prism/src/prism/PrismCL.java

@ -2099,7 +2099,8 @@ public class PrismCL implements PrismModelListener
} }
// check not trying to do gauss-seidel with mtbdd engine // check not trying to do gauss-seidel with mtbdd engine
if (prism.getEngine() == Prism.MTBDD) {
// (if we are in test mode, we ignore here; will lead to appropriate 'not supported' error handling during testing)
if (prism.getEngine() == Prism.MTBDD && !test) {
j = prism.getLinEqMethod(); j = prism.getLinEqMethod();
if (j == Prism.GAUSSSEIDEL || j == Prism.BGAUSSSEIDEL || j == Prism.PGAUSSSEIDEL || j == Prism.BPGAUSSSEIDEL) { if (j == Prism.GAUSSSEIDEL || j == Prism.BGAUSSSEIDEL || j == Prism.PGAUSSSEIDEL || j == Prism.BPGAUSSSEIDEL) {
errorAndExit("Gauss-Seidel and its variants are currently not supported by the MTBDD engine"); errorAndExit("Gauss-Seidel and its variants are currently not supported by the MTBDD engine");
@ -2110,7 +2111,8 @@ public class PrismCL implements PrismModelListener
} }
// or pseudo methods with sparse engine // or pseudo methods with sparse engine
else if (prism.getEngine() == Prism.SPARSE) {
// (if we are in test mode, we ignore here; will lead to appropriate 'not supported' error handling during testing)
else if (prism.getEngine() == Prism.SPARSE && !test) {
j = prism.getLinEqMethod(); j = prism.getLinEqMethod();
if (j == Prism.PGAUSSSEIDEL || j == Prism.BPGAUSSSEIDEL || j == Prism.PSOR || j == Prism.BPSOR) { if (j == Prism.PGAUSSSEIDEL || j == Prism.BPGAUSSSEIDEL || j == Prism.PSOR || j == Prism.BPSOR) {
errorAndExit("Pseudo Gauss-Seidel/SOR methods are currently not supported by the sparse engine"); errorAndExit("Pseudo Gauss-Seidel/SOR methods are currently not supported by the sparse engine");

Loading…
Cancel
Save