Package org.apache.rat
Interface OptionCollectionTest.OptionTest
- Enclosing class:
- OptionCollectionTest
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Defines the test method that is stored in a map.
-
Method Summary
Modifier and TypeMethodDescriptionvoidexec()Executes the test and uses fail or asserts to generate failures.default StringFormats the messages by adding the test name.default Stringname()Get the name of the test.namedTest(String providerName, String name, OptionCollectionTest.OptionTest test) Creates a named OptionTest.default voidtest()Execute the test and ensure any failures have the test name added.
-
Method Details
-
exec
void exec()Executes the test and uses fail or asserts to generate failures. -
test
default void test()Execute the test and ensure any failures have the test name added. -
formatMsg
Formats the messages by adding the test name.- Parameters:
msg- the message to reformat.- Returns:
- the formatted message.
-
name
Get the name of the test. By default, this method returnstoString().- Returns:
- the name of the test.
-
namedTest
static OptionCollectionTest.OptionTest namedTest(String providerName, String name, OptionCollectionTest.OptionTest test) Creates a named OptionTest.- Parameters:
name- the name of the test.test- the test to execute.- Returns:
- a named option test.
-