use of com.mulesoft.tools.migration.project.model.pom.Dependency in project mule-migration-assistant by mulesoft.
the class ThrottlingMigrationTaskTestCase method assertPomModel.
private void assertPomModel() {
PomModel pomModel = appModel.getPomModel().get();
assertThat(pomModel.getDependencies().size(), is(2));
Dependency httpTransformDependency = pomModel.getDependencies().get(0);
assertThat(httpTransformDependency.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(httpTransformDependency.getArtifactId(), is(MULE_HTTP_POLICY_TRANSFORM_EXTENSION_ARTIFACT_ID));
assertThat(httpTransformDependency.getVersion(), is(notNullValue()));
assertThat(httpTransformDependency.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
Dependency policyTransformExtensionDependency = pomModel.getDependencies().get(1);
assertThat(policyTransformExtensionDependency.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(policyTransformExtensionDependency.getArtifactId(), is(MULE_THROTTLING_EXTENSION_ARTIFACT_ID));
assertThat(policyTransformExtensionDependency.getVersion(), is(notNullValue()));
assertThat(policyTransformExtensionDependency.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
}
use of com.mulesoft.tools.migration.project.model.pom.Dependency in project mule-migration-assistant by mulesoft.
the class XmlPolicyTagMigrationStepTestCase method xmlPomContributionTest.
@Test
public void xmlPomContributionTest() {
XmlPolicyTagMigrationStep step = new XmlPolicyTagMigrationStep();
step.setApplicationModel(appModel);
Element element = appModel.getNode(XPATH_NODE_EXPRESSION);
step.execute(element, reportMock);
PomModel pm = appModel.getPomModel().get();
assertThat(pm.getDependencies().size(), is(1));
Dependency xmlThreatProtectionDependency = pm.getDependencies().get(0);
assertThat(xmlThreatProtectionDependency.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(xmlThreatProtectionDependency.getArtifactId(), is(MULE_XML_THREAT_PROTECTION_EXTENSION_ARTIFACT_ID));
assertThat(xmlThreatProtectionDependency.getVersion(), is(notNullValue()));
assertThat(xmlThreatProtectionDependency.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
assertCompleteXmlPolicyTag(element);
}
use of com.mulesoft.tools.migration.project.model.pom.Dependency in project mule-migration-assistant by mulesoft.
the class IpFilterMigrationTaskTestCase method assertPomModel.
private void assertPomModel() {
PomModel pomModel = appModel.getPomModel().get();
assertThat(pomModel.getDependencies().size(), is(4));
Dependency ipFilterExtension = pomModel.getDependencies().get(3);
assertThat(ipFilterExtension.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(ipFilterExtension.getArtifactId(), is(MULE_IP_FILTER_EXTENSION_ARTIFACT_ID));
assertThat(ipFilterExtension.getVersion(), is(notNullValue()));
assertThat(ipFilterExtension.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
}
use of com.mulesoft.tools.migration.project.model.pom.Dependency in project mule-migration-assistant by mulesoft.
the class ProxyMigrationTaskTestCase method assertWsdlDependency.
private void assertWsdlDependency(PomModel pomModel, int position) {
Dependency wsdlExtensionDependency = pomModel.getDependencies().get(position);
assertThat(wsdlExtensionDependency.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(wsdlExtensionDependency.getArtifactId(), is(MULE_WSDL_FUNCTIONS_EXTENSION_ARTIFACT_ID));
assertThat(wsdlExtensionDependency.getVersion(), is(notNullValue()));
assertThat(wsdlExtensionDependency.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
}
use of com.mulesoft.tools.migration.project.model.pom.Dependency in project mule-migration-assistant by mulesoft.
the class SlaBasedAlgorithmMigrationStepTestCase method rateLimitSlaPomContributionTest.
@Test
public void rateLimitSlaPomContributionTest() throws Exception {
SlaBasedAlgorithmMigrationStep step = new SlaBasedAlgorithmMigrationStep();
step.setApplicationModel(appModel);
Element element = getSlaPolicy(1, false);
step.execute(element, reportMock);
PomModel pm = appModel.getPomModel().get();
assertThat(pm.getDependencies().size(), is(2));
Dependency policyTransformExtensionDependency = pm.getDependencies().get(1);
assertThat(policyTransformExtensionDependency.getGroupId(), is(COM_MULESOFT_ANYPOINT_GROUP_ID));
assertThat(policyTransformExtensionDependency.getArtifactId(), is(MULE_THROTTLING_EXTENSION_ARTIFACT_ID));
assertThat(policyTransformExtensionDependency.getVersion(), is(notNullValue()));
assertThat(policyTransformExtensionDependency.getClassifier(), is(MULE_PLUGIN_CLASSIFIER));
}
Aggregations