&& !LangUtil.isEmpty(comment)) {
out.printAttribute(xmlNames.commentName, comment);
}
+ if (isStaging && !LangUtil.isEmpty(xmlNames.stagingName)) {
+ out.printAttribute(xmlNames.commentName, comment);
+ }
}
/**
public static class XMLNames {
public static final XMLNames DEFAULT =
new XMLNames(null, "description", "sourceLocation",
- "keywords", "options", "paths", "comment", false, false, false);
+ "keywords", "options", "paths", "comment",
+ "staging", false, false, false);
final String descriptionName;
final String sourceLocationName;
final String keywordsName;
final String optionsName;
final String pathsName;
final String commentName;
+ final String stagingName;
final boolean skipDirChanges;
final boolean skipMessages;
final boolean skipChildren;
+ // not runtime, skipAll, skipIfAnyChildSkipped, skipSet
+ // sourceLocations
/** reset all names/behavior or pass defaultNames
* as the defaults for any null elements
*/
String optionsName,
String pathsName,
String commentName,
+ String stagingName,
boolean skipDirChanges,
boolean skipMessages,
boolean skipChildren) {
this.optionsName = (null != optionsName ? optionsName : defaultNames.optionsName);
this.pathsName = (null != pathsName ? pathsName : defaultNames.pathsName);
this.commentName = (null != commentName ? commentName : defaultNames.commentName);
+ this.stagingName = (null != stagingName ? stagingName : defaultNames.stagingName);
} else {
this.descriptionName = descriptionName;
this.sourceLocationName = sourceLocationName;
this.optionsName = optionsName;
this.pathsName = pathsName;
this.commentName = commentName;
+ this.stagingName = stagingName;
}
}
}
/**
* do description as title, do sourceLocation,
* do keywords, do options, skip paths, do comment,
+ * skip staging,
* skip dirChanges, do messages and do children
* (though we do children directly).
*/
private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT,
- "title", null, null, null, "", null, true, false, false);
+ "title", null, null, null, "", null, "", true, false, false);
private static final String OPTION_PREFIX = "-ajctest";
private static final String[] VALID_OPTIONS = new String[] { OPTION_PREFIX };
public static final String XMLNAME = "suite";
/**
* do description, do sourceLocation,
- * do keywords, do options, skip paths, do comment
+ * do keywords, do options, skip paths, do comment,
+ * skip staging,
* skip dirChanges, skip messages and do children
* (though we do children directly).
*/
private static final XMLNames NAMES = new XMLNames(XMLNames.DEFAULT,
- null, null, null, null, "", null, true, true, false);
+ null, null, null, null, "", null, "", true, true, false);
File suiteDir;
public Spec() {
super(XMLNAME, false); // do not skip this even if children skip