Search in sources :

Example 46 with ZapXmlConfiguration

use of org.zaproxy.zap.utils.ZapXmlConfiguration in project zaproxy by zaproxy.

the class AddOnUnitTest method shouldNotDirectlyDependOnNonDirectDependency.

@Test
public void shouldNotDirectlyDependOnNonDirectDependency() throws Exception {
    // Given
    ZapXmlConfiguration zapVersionsXml = createZapVersionsXml();
    AddOn addOn = createAddOn("AddOn1", zapVersionsXml);
    AddOn nonDirectDependency = createAddOn("AddOn8", zapVersionsXml);
    // When
    boolean depends = addOn.dependsOn(nonDirectDependency);
    // Then
    assertThat(depends, is(equalTo(false)));
}
Also used : ZapXmlConfiguration(org.zaproxy.zap.utils.ZapXmlConfiguration) Test(org.junit.Test)

Aggregations

ZapXmlConfiguration (org.zaproxy.zap.utils.ZapXmlConfiguration)46 Test (org.junit.Test)18 File (java.io.File)8 ConfigurationException (org.apache.commons.configuration.ConfigurationException)6 IOException (java.io.IOException)5 Configuration (org.apache.commons.configuration.Configuration)5 XMLConfiguration (org.apache.commons.configuration.XMLConfiguration)3 StructuralNodeModifier (org.zaproxy.zap.model.StructuralNodeModifier)3 StringReader (java.io.StringReader)2 InvocationTargetException (java.lang.reflect.InvocationTargetException)2 InvalidParameterException (java.security.InvalidParameterException)2 ConversionException (org.apache.commons.configuration.ConversionException)2 Before (org.junit.Before)2 RecordContext (org.parosproxy.paros.db.RecordContext)2 FileCopier (org.parosproxy.paros.model.FileCopier)2 HttpMessage (org.parosproxy.paros.network.HttpMessage)2 Context (org.zaproxy.zap.model.Context)2 ParameterParser (org.zaproxy.zap.model.ParameterParser)2 StandardParameterParser (org.zaproxy.zap.model.StandardParameterParser)2 Tech (org.zaproxy.zap.model.Tech)2