SLING-8121 Rename feature 'include' to 'prototype'
diff --git a/src/main/java/org/apache/sling/feature/modelconverter/FeatureToProvisioning.java b/src/main/java/org/apache/sling/feature/modelconverter/FeatureToProvisioning.java
index 7dbb30d..dca1a69 100644
--- a/src/main/java/org/apache/sling/feature/modelconverter/FeatureToProvisioning.java
+++ b/src/main/java/org/apache/sling/feature/modelconverter/FeatureToProvisioning.java
@@ -75,8 +75,8 @@
}
org.apache.sling.feature.Feature feature = getFeature(inputFile);
- if (feature.getInclude() != null) {
- feature = handleIncludes(feature, additionalInputFiles, fp);
+ if (feature.getPrototype() != null) {
+ feature = handlePrototype(feature, additionalInputFiles, fp);
}
Object featureNameVar = feature.getVariables().remove(PROVISIONING_MODEL_NAME_VARIABLE);
@@ -107,7 +107,7 @@
}
- private static org.apache.sling.feature.Feature handleIncludes(org.apache.sling.feature.Feature feature, File[] additionalFiles, FeatureProvider fp) throws UncheckedIOException {
+ private static org.apache.sling.feature.Feature handlePrototype(org.apache.sling.feature.Feature feature, File[] additionalFiles, FeatureProvider fp) throws UncheckedIOException {
Map<ArtifactId, org.apache.sling.feature.Feature> features =
Stream.of(additionalFiles)
.map(FeatureToProvisioning::getFeature)
diff --git a/src/test/java/org/apache/sling/feature/modelconverter/ModelConverterTest.java b/src/test/java/org/apache/sling/feature/modelconverter/ModelConverterTest.java
index cc8cdec..498cb2e 100644
--- a/src/test/java/org/apache/sling/feature/modelconverter/ModelConverterTest.java
+++ b/src/test/java/org/apache/sling/feature/modelconverter/ModelConverterTest.java
@@ -468,7 +468,7 @@
assertEquals(expected.getFrameworkProperties(), actual.getFrameworkProperties());
assertExtensionEqual(expected.getExtensions(), actual.getExtensions());
- // Ignore caps and reqs, includes and here since they cannot come from the prov model.
+ // Ignore caps and reqs, prototype and here since they cannot come from the prov model.
}
private void assertBundlesEqual(Bundles expected, Bundles actual) {
diff --git a/src/test/resources/simple_inherits.json b/src/test/resources/simple_inherits.json
index d9d02e9..fd4a0be 100644
--- a/src/test/resources/simple_inherits.json
+++ b/src/test/resources/simple_inherits.json
@@ -1,6 +1,6 @@
{
"id":"generated:simple-inherits:1.0.0",
- "include":
+ "prototype":
{
"id": "generated:simple:1.0.0"
},