TOP

Library net/mdatools/modelant/util/assert.xml

Publishes macros to test Ant scripts Usage:

<typedef resource="net/mdatools/modelant/util/assert.xml"/>

NOTE: Importing this library makes the Ant properties variable.
Tasks and Macros Description
assert.containing Validate the value of the property named is a list that contians the explicit string value
assert.defined Assert that the property with the name provided has been defined
assert.empty Validate the value of the property named is an empty string or list
assert.equals Compare two trimmed string values. Fail with the [default] message if the strings are not equal
assert.fail Test if the nested tasks fail / throw an exception
assert.false Test if the nested condition evaluates to false
assert.file.does.not.exist Assert the file does not exist, otherwise fail with the message
assert.file.exists Assert the file exists, otherwise fail with the message
assert.matches Test if a string matches a regular expression. If they do not match, fail with the [default] message.
assert.not.containing Validate the value of the property named is a list that does NOT contain the provided explicit string value
assert.not.defined Assert that the property with the name provided is not defined
assert.not.empty Validate the value of the property named is not an empty string or list
assert.not.equals Compare two trimmed string values. Fail with the [default] message if the strings are equal
assert.size.equals Validate the value of the property named is list of the stated size
assert.size.not.equals Validate the value of the property named is list of other than the stated size
assert.true Test if the nested condition evaluates to true
log.capture Capture any logged messages of the nested tasks and stores them in the target property for analysis. Nevertheless the logged messages are printed. If an exception is thrown, it is suppressesed and stored in exception.@{name} property. Do not nest instances of this macro.

Documentation generated by ant.doc Ant macro from ModelAnt by MDA Tools