Search in sources :

Example 1 with FilterExpression

use of org.apache.axis2.transport.testkit.filter.FilterExpression in project wso2-axis2-transports by wso2.

the class ManagedTestSuite method addTest.

@Override
public void addTest(Test test) {
    if (test instanceof ManagedTestCase) {
        ManagedTestCase ttest = (ManagedTestCase) test;
        Map<String, String> map = ttest.getNameComponents();
        boolean excluded = false;
        for (FilterExpression exclude : excludes) {
            if (exclude.matches(map)) {
                excluded = true;
                break;
            }
        }
        if (excluded != invertExcludes) {
            return;
        }
        ttest.init(StringUtils.leftPad(String.valueOf(nextId++), 4, '0'), reuseResources, testClass);
        ttest.getResourceSet().resolve();
    }
    super.addTest(test);
}
Also used : ManagedTestCase(org.apache.axis2.transport.testkit.tests.ManagedTestCase) FilterExpression(org.apache.axis2.transport.testkit.filter.FilterExpression)

Aggregations

FilterExpression (org.apache.axis2.transport.testkit.filter.FilterExpression)1 ManagedTestCase (org.apache.axis2.transport.testkit.tests.ManagedTestCase)1