You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ju...@apache.org on 2014/01/22 18:36:42 UTC
svn commit: r1560437 [3/3] - in /sling/trunk: ./ bundles/extensions/models/
bundles/extensions/models/api/ bundles/extensions/models/api/src/
bundles/extensions/models/api/src/main/
bundles/extensions/models/api/src/main/java/ bundles/extensions/models...
Added: sling/trunk/bundles/extensions/models/integration-tests/pom.xml
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/integration-tests/pom.xml?rev=1560437&view=auto
==============================================================================
--- sling/trunk/bundles/extensions/models/integration-tests/pom.xml (added)
+++ sling/trunk/bundles/extensions/models/integration-tests/pom.xml Wed Jan 22 17:36:40 2014
@@ -0,0 +1,319 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>sling</artifactId>
+ <version>18</version>
+ <relativePath>../../../../parent/pom.xml</relativePath>
+ </parent>
+
+ <artifactId>org.apache.sling.models.integration-tests</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <packaging>jar</packaging>
+
+ <name>Apache Sling Models Integration Tests</name>
+ <description>Apache Sling Models Integration Tests</description>
+
+ <!--
+ To keep the instance under test running and run individual tests
+ against it, use:
+
+ mvn clean verify -DkeepJarRunning=true -Dhttp.port=8080
+
+ optionally using jar.executor.vm.options to enable remote debugging,
+ and in another console:
+
+ mvn -o verify -Dtests.to.run=**/**Test.java -Dtest.server.url=http://localhost:8080
+
+ optionally using -Dmaven.surefire.debug to enable debugging.
+ -->
+ <properties>
+ <!-- Set this to run the server on a specific port
+ <http.port></http.port>
+ -->
+
+ <!-- Set this to run tests against an existing server instance -->
+ <keepJarRunning>false</keepJarRunning>
+
+ <!-- URL of a server against which to run tests -->
+ <test.server.url />
+
+ <!-- Set this to run tests against a specific hostname, if test.server.url is not set-->
+ <test.server.hostname />
+
+ <!-- Set this to use a different username for remote execution of sling junit tests -->
+ <test.server.username />
+
+ <!-- Set this to use a different password for remote execution of sling junit tests -->
+ <test.server.password />
+
+ <!-- Options for the VM that executes our runnable jar -->
+ <jar.executor.vm.options>-Xmx512m</jar.executor.vm.options>
+
+ <!-- Change this to use longer or shorter timeouts for testing -->
+ <sling.testing.timeout.multiplier>1.0</sling.testing.timeout.multiplier>
+
+ <!-- Set this to run the executable jar in a specified filesystem folder -->
+ <jar.executor.work.folder />
+
+ <!-- Options for the jar to execute. $JAREXEC_SERVER_PORT$ is replaced by the
+ selected port number -->
+ <jar.executor.jar.options>-p $JAREXEC_SERVER_PORT$</jar.executor.jar.options>
+
+ <!-- Change this to run selected tests only -->
+ <tests.to.run>**/**Test.java</tests.to.run>
+ </properties>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-clean-plugin</artifactId>
+ <configuration>
+ <filesets>
+ <fileset>
+ <directory>${basedir}</directory>
+ <includes>
+ <!-- sling folder is the workdir of the executable jar that we test -->
+ <include>sling/**</include>
+ </includes>
+ </fileset>
+ </filesets>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>copy-runnable-jar</id>
+ <goals>
+ <goal>copy-dependencies</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <includeArtifactIds>org.apache.sling.launchpad</includeArtifactIds>
+ <excludeTransitive>true</excludeTransitive>
+ <overWriteReleases>false</overWriteReleases>
+ <overWriteSnapshots>false</overWriteSnapshots>
+ </configuration>
+ </execution>
+ <execution>
+ <!--
+ Consider all dependencies as candidates to be installed
+ as additional bundles. We use system properties to define
+ which bundles to install in which order.
+ -->
+ <id>copy-additional-bundles</id>
+ <goals>
+ <goal>copy-dependencies</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <outputDirectory>${project.build.directory}/sling/additional-bundles</outputDirectory>
+ <excludeTransitive>true</excludeTransitive>
+ <overWriteReleases>false</overWriteReleases>
+ <overWriteSnapshots>false</overWriteSnapshots>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <!-- Find free ports to run our server -->
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>reserve-server-port</id>
+ <goals>
+ <goal>reserve-network-port</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <portNames>
+ <portName>http.port</portName>
+ </portNames>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <!-- We run all tests in the integration-tests phase -->
+ <excludes>
+ <exclude>**</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>integration-test</id>
+ <goals>
+ <goal>integration-test</goal>
+ </goals>
+ </execution>
+ <execution>
+ <id>verify</id>
+ <goals>
+ <goal>verify</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <debugForkedProcess>${maven.surefire.debug}</debugForkedProcess>
+ <includes>
+ <include>${tests.to.run}</include>
+ </includes>
+ <systemPropertyVariables>
+ <test.server.url>${test.server.url}</test.server.url>
+ <test.server.hostname>${test.server.hostname}</test.server.hostname>
+ <test.server.username>${test.server.username}</test.server.username>
+ <test.server.password>${test.server.password}</test.server.password>
+ <jar.executor.server.port>${http.port}</jar.executor.server.port>
+ <jar.executor.vm.options>${jar.executor.vm.options}</jar.executor.vm.options>
+ <jar.executor.jar.folder>${project.basedir}/target/dependency</jar.executor.jar.folder>
+ <jar.executor.jar.name.regexp>org.apache.sling.launchpad.*jar$</jar.executor.jar.name.regexp>
+ <jar.executor.work.folder>${jar.executor.work.folder}</jar.executor.work.folder>
+ <jar.executor.jar.options>${jar.executor.jar.options}</jar.executor.jar.options>
+ <additional.bundles.path>${project.basedir}/target/sling/additional-bundles</additional.bundles.path>
+ <keepJarRunning>${keepJarRunning}</keepJarRunning>
+ <server.ready.timeout.seconds>60</server.ready.timeout.seconds>
+ <sling.testing.timeout.multiplier>${sling.testing.timeout.multiplier}</sling.testing.timeout.multiplier>
+ <server.ready.path.1>/:script src="system/sling.js"</server.ready.path.1>
+ <server.ready.path.2>/.explorer.html:href="/libs/sling/explorer/css/explorer.css"</server.ready.path.2>
+ <server.ready.path.3>/sling-test/sling/sling-test.html:Sling client library tests</server.ready.path.3>
+ <start.bundles.timeout.seconds>30</start.bundles.timeout.seconds>
+ <bundle.install.timeout.seconds>20</bundle.install.timeout.seconds>
+
+ <!--
+ Define additional bundles to install by specifying the beginning of their artifact name.
+ The bundles are installed in lexical order of these property names.
+ All bundles must be listed as dependencies in this pom, or they won't be installed.
+ -->
+ <sling.additional.bundle.1>org.apache.sling.junit.core</sling.additional.bundle.1>
+ <sling.additional.bundle.10>org.apache.sling.models.api</sling.additional.bundle.10>
+ <sling.additional.bundle.11>org.apache.sling.models.impl</sling.additional.bundle.11>
+ <sling.additional.bundle.12>org.apache.sling.models.server-side-tests</sling.additional.bundle.12>
+ <!--
+ <sling.additional.bundle.2>org.apache.sling.junit.scriptable</sling.additional.bundle.2>
+ <sling.additional.bundle.3>org.apache.sling.junit.remote</sling.additional.bundle.3>
+ <sling.additional.bundle.4>org.apache.sling.testing.tools</sling.additional.bundle.4>
+ <sling.additional.bundle.5>httpclient-osgi</sling.additional.bundle.5>
+ <sling.additional.bundle.6>httpcore-osgi</sling.additional.bundle.6>
+ -->
+ </systemPropertyVariables>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <dependencies>
+ <!-- Additional bundles needed by the Sling instance under test -->
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.junit.core</artifactId>
+ <version>1.0.8</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.junit.remote</artifactId>
+ <version>1.0.8</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.testing.tools</artifactId>
+ <version>1.0.6</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.models.api</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.models.impl</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.models.server-side-tests</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <!-- sling testing tools bundles requires httpclient -->
+ <dependency>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpclient-osgi</artifactId>
+ <version>4.1.2</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.httpcomponents</groupId>
+ <artifactId>httpcore-osgi</artifactId>
+ <version>4.1.2</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <!-- actual dependencies -->
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.commons.json</artifactId>
+ <version>2.0.6</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.launchpad</artifactId>
+ <classifier>standalone</classifier>
+ <version>7-SNAPSHOT</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>1.4</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-simple</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
Added: sling/trunk/bundles/extensions/models/integration-tests/src/test/java/org/apache/sling/models/it/RemoteTest.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/integration-tests/src/test/java/org/apache/sling/models/it/RemoteTest.java?rev=1560437&view=auto
==============================================================================
--- sling/trunk/bundles/extensions/models/integration-tests/src/test/java/org/apache/sling/models/it/RemoteTest.java (added)
+++ sling/trunk/bundles/extensions/models/integration-tests/src/test/java/org/apache/sling/models/it/RemoteTest.java Wed Jan 22 17:36:40 2014
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sling.models.it;
+
+import org.apache.sling.junit.remote.testrunner.SlingRemoteTestParameters;
+import org.apache.sling.junit.remote.testrunner.SlingRemoteTestRunner;
+import org.apache.sling.testing.tools.sling.SlingTestBase;
+import org.junit.runner.RunWith;
+
+@RunWith(SlingRemoteTestRunner.class)
+public class RemoteTest extends SlingTestBase implements SlingRemoteTestParameters {
+
+ public String getJunitServletUrl() {
+ return getServerBaseUrl() + "/system/sling/junit";
+ }
+
+ public String getTestClassesSelector() {
+ return "org.apache.sling.models";
+ }
+
+ public String getTestMethodSelector() {
+ return null;
+ }
+
+}
Added: sling/trunk/bundles/extensions/models/server-side-tests/pom.xml
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/server-side-tests/pom.xml?rev=1560437&view=auto
==============================================================================
--- sling/trunk/bundles/extensions/models/server-side-tests/pom.xml (added)
+++ sling/trunk/bundles/extensions/models/server-side-tests/pom.xml Wed Jan 22 17:36:40 2014
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor
+ license agreements. See the NOTICE file distributed with this work for additional
+ information regarding copyright ownership. The ASF licenses this file to
+ you under the Apache License, Version 2.0 (the "License"); you may not use
+ this file except in compliance with the License. You may obtain a copy of
+ the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required
+ by applicable law or agreed to in writing, software distributed under the
+ License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
+ OF ANY KIND, either express or implied. See the License for the specific
+ language governing permissions and limitations under the License. -->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>sling</artifactId>
+ <version>18</version>
+ <relativePath>../../../../parent/pom.xml</relativePath>
+ </parent>
+ <artifactId>org.apache.sling.models.server-side-tests</artifactId>
+ <packaging>bundle</packaging>
+ <version>0.0.1-SNAPSHOT</version>
+ <name>Sling Models ITs</name>
+ <description>Sling Models ITs</description>
+ <scm>
+ <connection>scm:svn:http://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/models/server-side-tests</connection>
+ <developerConnection> scm:svn:https://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/models/server-side-tests</developerConnection>
+ <url>http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/server-side-tests</url>
+ </scm>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-scr-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>maven-bundle-plugin</artifactId>
+ <extensions>true</extensions>
+ <configuration>
+ <instructions>
+ <Sling-Model-Packages>
+ org.apache.sling.models.it.models
+ </Sling-Model-Packages>
+ <Sling-Test-Regexp>.*Test</Sling-Test-Regexp>
+ <Export-Package>org.apache.sling.models.it</Export-Package>
+ </instructions>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.models.api</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.compendium</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.core</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.api</artifactId>
+ <version>2.2.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>org.apache.felix.scr.annotations</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.junit.core</artifactId>
+ <version>1.0.8</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.jcr</groupId>
+ <artifactId>jcr</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.inject</groupId>
+ <artifactId>javax.inject</artifactId>
+ <version>1</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.commons.osgi</artifactId>
+ <version>2.2.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>commons-lang</groupId>
+ <artifactId>commons-lang</artifactId>
+ <version>2.5</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-simple</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
Added: sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/SimpleTest.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/SimpleTest.java?rev=1560437&view=auto
==============================================================================
--- sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/SimpleTest.java (added)
+++ sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/SimpleTest.java Wed Jan 22 17:36:40 2014
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sling.models.it;
+
+import static org.junit.Assert.*;
+
+import javax.jcr.Node;
+import javax.jcr.Session;
+
+import org.apache.commons.lang.RandomStringUtils;
+import org.apache.sling.api.resource.Resource;
+import org.apache.sling.api.resource.ResourceResolver;
+import org.apache.sling.api.resource.ResourceResolverFactory;
+import org.apache.sling.junit.annotations.SlingAnnotationsTestRunner;
+import org.apache.sling.junit.annotations.TestReference;
+import org.apache.sling.models.it.models.TestModel;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+@RunWith(SlingAnnotationsTestRunner.class)
+public class SimpleTest {
+
+ @TestReference
+ private ResourceResolverFactory rrFactory;
+
+ @Test
+ public void test() throws Exception {
+ String value = RandomStringUtils.randomAlphanumeric(10);
+
+ ResourceResolver resolver = null;
+ Node createdNode = null;
+ try {
+ resolver = rrFactory.getAdministrativeResourceResolver(null);
+ Session session = resolver.adaptTo(Session.class);
+ Node rootNode = session.getRootNode();
+ createdNode = rootNode.addNode("test_" + RandomStringUtils.randomAlphanumeric(10));
+ createdNode.setProperty("testProperty", value);
+ session.save();
+
+ Resource resource = resolver.getResource(createdNode.getPath());
+
+ TestModel model = resource.adaptTo(TestModel.class);
+
+ assertNotNull("Model is null", model);
+ assertEquals("Test Property is not set correctly", value, model.getTestProperty());
+ assertNotNull("Filters is null", model.getFilters());
+ } finally {
+ if (createdNode != null) {
+ createdNode.remove();
+ }
+ if (resolver != null) {
+ resolver.close();
+ }
+ }
+ }
+}
Added: sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/models/TestModel.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/models/TestModel.java?rev=1560437&view=auto
==============================================================================
--- sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/models/TestModel.java (added)
+++ sling/trunk/bundles/extensions/models/server-side-tests/src/main/java/org/apache/sling/models/it/models/TestModel.java Wed Jan 22 17:36:40 2014
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sling.models.it.models;
+
+import java.util.List;
+
+import javax.inject.Inject;
+import javax.servlet.Filter;
+
+import org.apache.sling.api.resource.Resource;
+import org.apache.sling.models.annotations.Model;
+
+@Model(adaptables=Resource.class)
+public class TestModel {
+
+ @Inject
+ private String testProperty;
+
+ @Inject
+ private List<Filter> filters;
+
+ public String getTestProperty() {
+ return testProperty;
+ }
+
+ public List<Filter> getFilters() {
+ return filters;
+ }
+}
Modified: sling/trunk/pom.xml
URL: http://svn.apache.org/viewvc/sling/trunk/pom.xml?rev=1560437&r1=1560436&r2=1560437&view=diff
==============================================================================
--- sling/trunk/pom.xml (original)
+++ sling/trunk/pom.xml Wed Jan 22 17:36:40 2014
@@ -185,7 +185,11 @@
<module>bundles/extensions/explorer</module>
<module>bundles/extensions/healthcheck</module>
<module>bundles/resourceaccesssecurity</module>
-
+ <module>bundles/extensions/models/api</module>
+ <module>bundles/extensions/models/impl</module>
+ <module>bundles/extensions/models/server-side-tests</module>
+ <module>bundles/extensions/models/integration-tests</module>
+
<!-- Testing Support -->
<module>testing/tools</module>
<module>testing/junit/core</module>