Browse Source

Regression tests: detect and warn about spaces in Error RESULT specifications.

git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10262 bbc10eb1-c90d-0410-af57-cb519fbb1720
master
Dave Parker 11 years ago
parent
commit
9f6777bed5
  1. 3
      prism/src/parser/ast/Property.java

3
prism/src/parser/ast/Property.java

@ -266,6 +266,9 @@ public class Property extends ASTElement
if (strExpected.startsWith("Error:")) {
String words[] = strExpected.substring(6).split(",");
for (String word : words) {
if (word.length() == 0) {
throw new PrismException("Invalid RESULT specification: no expected words immediately following 'Error:'");
}
if (!errMsg.toLowerCase().contains(word)) {
throw new PrismException("Error message should contain \"" + word + "\"");
}

Loading…
Cancel
Save