You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by ss...@apache.org on 2021/12/01 18:04:34 UTC

[sling-org-apache-sling-models-integration-tests] branch feature/SLING-10948-update-integration-tests updated (92f6d4d -> 30a8286)

This is an automated email from the ASF dual-hosted git repository.

sseifert pushed a change to branch feature/SLING-10948-update-integration-tests
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-models-integration-tests.git.


 discard 92f6d4d  switch to bundle-parent 46 and OSGi annotations
 discard 124710b  comment beanutils dependency
 discard 8454ce6  register models via bnd plugin
 discard aacf60b  switch to commons lang 3
 discard 58d4407  simplify provisioning config
 discard 81d8047  organize imports
 discard 461ca6d  update dependencies
 discard 6f5cf84  cleanup dependencies
 discard 4e4baea  switch to slingstart-maven-plugin and sling 11
 discard a3e26e5  update to java 8
     new 30a8286  SLING-10954 Update Models Integration Tests to Sling 11 and Parent 46

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (92f6d4d)
            \
             N -- N -- N   refs/heads/feature/SLING-10948-update-integration-tests (30a8286)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:

[sling-org-apache-sling-models-integration-tests] 01/01: SLING-10954 Update Models Integration Tests to Sling 11 and Parent 46

Posted by ss...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sseifert pushed a commit to branch feature/SLING-10948-update-integration-tests
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-models-integration-tests.git

commit 30a82867217243844d5dcd558ba30adf85c4d79a
Author: Stefan Seifert <st...@users.noreply.github.com>
AuthorDate: Wed Dec 1 19:02:37 2021 +0100

    SLING-10954 Update Models Integration Tests to Sling 11 and Parent 46
---
 bnd.bnd                                            |   7 +
 pom.xml                                            | 372 ++++++++-------------
 .../it/delegate/request/DelegateBaseModel.java     |   4 +-
 .../request/package-info.java}                     |  18 +-
 .../it/delegate/resource/DelegateBaseModel.java    |   4 +-
 .../{DelegateBaseModel.java => package-info.java}  |  28 +-
 .../sling/models/it/exporter/BaseComponent.java    |   1 -
 .../models/it/exporter/BaseRequestComponent.java   |  12 +-
 .../sling/models/it/exporter/ComponentImpl.java    |   4 +-
 .../models/it/exporter/DoubledFirstComponent.java  |   4 -
 .../models/it/exporter/ExtendedComponent.java      |   4 +-
 .../it/exporter/ExtendedRequestComponent.java      |  12 +-
 .../models/it/exporter/RequestComponentImpl.java   |   4 +-
 ...oubledFirstComponent.java => package-info.java} |  19 +-
 .../implpicker/CustomLastImplementationPicker.java |  17 +-
 .../package-info.java}                             |  18 +-
 .../models/it/models/RequestSelfModelImpl.java     |   1 -
 .../package-info.java}                             |  18 +-
 ...RequestSelfModelImpl.java => package-info.java} |  18 +-
 .../package-info.java}                             |  18 +-
 .../package-info.java}                             |  18 +-
 .../AnotherTestBindingsValuesProvider.java         |  14 +-
 .../it/services/TestBindingsValuesProvider.java    |  12 +-
 .../models/it/services/TestResourceDecorator.java  |  12 +-
 ...ndingsValuesProvider.java => package-info.java} |  20 +-
 .../sling/models/it/servlets/PathBoundServlet.java |  15 +-
 .../customizers/SM_TeleporterCustomizer.java       |   2 -
 .../apache/sling/models/testing/DecoratedIT.java   |  13 +-
 .../sling/models/testing/ImplementsExtendsIT.java  |   2 +-
 .../testing/InjectorSpecificAnnotationIT.java      |   3 +-
 .../sling/models/testing/ModelFactorySimpleIT.java |   2 +-
 .../ServiceInjectionWithDifferentRankingIT.java    |   2 +-
 .../org/apache/sling/models/testing/SimpleIT.java  |   8 +-
 .../org/apache/sling/models/testing/ViaIT.java     |   5 +-
 .../models/testing/delegate/DelegateRequestIT.java |  12 +-
 .../testing/delegate/DelegateResourceIT.java       |  12 +-
 .../sling/models/testing/exporter/ExporterIT.java  |   8 +-
 .../sling/models/testing/helper/FakeRequest.java   |  97 +++++-
 .../sling/models/testing/helper/FakeResponse.java  |  28 +-
 .../sling/models/testing/rtbound/FakeRequest.java  | 120 ++++++-
 .../rtboundpicker/ResourceTypePickerIT.java        |   6 +-
 .../provisioning/sling-models-jacksonexporter.txt  |  24 ++
 src/test/provisioning/sling.txt                    |  37 ++
 43 files changed, 547 insertions(+), 508 deletions(-)

diff --git a/bnd.bnd b/bnd.bnd
new file mode 100644
index 0000000..1aef1d3
--- /dev/null
+++ b/bnd.bnd
@@ -0,0 +1,7 @@
+Sling-Test-Regexp: .*Test
+
+Import-Package:\
+  org.apache.commons.beanutils;resolution:=optional,\
+  *
+
+-plugin: org.apache.sling.bnd.models.ModelsScannerPlugin
diff --git a/pom.xml b/pom.xml
index e36f4cf..eac4659 100644
--- a/pom.xml
+++ b/pom.xml
@@ -22,14 +22,13 @@
     <modelVersion>4.0.0</modelVersion>
     <parent>
         <groupId>org.apache.sling</groupId>
-        <artifactId>sling</artifactId>
-        <version>26</version>
+        <artifactId>sling-bundle-parent</artifactId>
+        <version>46</version>
         <relativePath/>
     </parent>
 
     <artifactId>org.apache.sling.models.integration-tests</artifactId>
     <version>0.0.1-SNAPSHOT</version>
-    <packaging>bundle</packaging>
 
     <name>Apache Sling Models Integration Tests</name>
     <description>
@@ -38,121 +37,33 @@
         remote test proxy that runs in the integration-tests phase.
     </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>
-        <sling.java.version>7</sling.java.version>
-        <!-- 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>
-        <!-- Alternative with JVM debug port
-        <jar.executor.vm.options>-Xmx512m -Xdebug -Xrunjdwp:server=y,transport=dt_socket,address=38080,suspend=n</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>
+        <sling.java.version>8</sling.java.version>
+        <!-- start with -DkeepITServerRunning=true to allow to rerun ITs or inspect the server after the ITs have been executed there -->
+        <keepITServerRunning>false</keepITServerRunning>
+        <project.build.outputTimestamp>2021-12-01T00:00:00Z</project.build.outputTimestamp>
     </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>
+                <groupId>biz.aQute.bnd</groupId>
+                <artifactId>bnd-maven-plugin</artifactId>
+                <dependencies>
+                    <dependency>
+                        <groupId>org.apache.sling</groupId>
+                        <artifactId>org.apache.sling.bnd.models</artifactId>
+                        <version>1.0.0</version>
+                    </dependency>
+                </dependencies>
             </plugin>
             <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-bundle-plugin</artifactId>
-                <extensions>true</extensions>
+                <groupId>biz.aQute.bnd</groupId>
+                <artifactId>bnd-baseline-maven-plugin</artifactId>
                 <configuration>
-                    <instructions>
-                        <Sling-Model-Packages>
-                            org.apache.sling.models.it.nonexisting,
-                            org.apache.sling.models.it.noclasses,
-                            org.apache.sling.models.it.models,
-                            org.apache.sling.models.it.rtbound,
-                            org.apache.sling.models.it.rtboundpicker,
-                            org.apache.sling.models.it.delegate.request,
-                            org.apache.sling.models.it.delegate.resource
-                        </Sling-Model-Packages>
-                        <Sling-Model-Classes>
-                            org.apache.sling.models.it.exporter.BaseComponent,
-                            org.apache.sling.models.it.exporter.ComponentImpl,
-                            org.apache.sling.models.it.exporter.ExtendedComponent,
-                            org.apache.sling.models.it.exporter.BaseRequestComponent,
-                            org.apache.sling.models.it.exporter.RequestComponentImpl,
-                            org.apache.sling.models.it.exporter.ExtendedRequestComponent,
-                            org.apache.sling.models.it.exporter.DoubledFirstComponent,
-                            org.apache.sling.models.it.exporter.DoubledSecondComponent
-                        </Sling-Model-Classes>
-                        <Sling-Test-Regexp>.*Test</Sling-Test-Regexp>
-                        <Export-Package>
-                            org.apache.sling.models.it.delegate.request,
-                            org.apache.sling.models.it.delegate.resource,
-                            org.apache.sling.models.it.exporter,
-                            org.apache.sling.models.it.implpicker,
-                            org.apache.sling.models.it.models,
-                            org.apache.sling.models.it.models.implextend,
-                            org.apache.sling.models.it.rtbound,
-                            org.apache.sling.models.it.rtboundpicker,
-                            org.apache.sling.models.it.services
-                        </Export-Package>
-                        <Import-Package>
-                            org.apache.commons.beanutils;resolution:=optional,
-                            *
-                        </Import-Package>
-                    </instructions>
+                    <skip>true</skip>
                 </configuration>
-            </plugin>
-            <plugin>
-                <groupId>org.apache.felix</groupId>
-                <artifactId>maven-scr-plugin</artifactId>
-            </plugin>
+           </plugin>
            <plugin>
                 <groupId>org.apache.rat</groupId>
                 <artifactId>apache-rat-plugin</artifactId>
@@ -165,117 +76,102 @@
                 </configuration>
             </plugin>
             <plugin>
-                <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-dependency-plugin</artifactId>
+                <!-- 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>pre-integration-test</phase>
+                        <configuration>
+                            <portNames>
+                                <!-- reserved port must be stored in property because it must be passed to the slingstart-maven-plugin -->
+                                <portName>http.port</portName>
+                            </portNames>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <!-- the Sling instance is provisioned from the model in src/main/provisioning/model.txt -->
+                <groupId>org.apache.sling</groupId>
+                <artifactId>slingstart-maven-plugin</artifactId>
+                <extensions>true</extensions>
                 <executions>
                     <execution>
-                        <id>copy-runnable-jar</id>
+                        <id>prepare-launchpad-package</id>
+                        <goals>
+                            <goal>prepare-package</goal>
+                        </goals>
+                        <phase>pre-integration-test</phase>
+                    </execution>
+                    <execution>
+                        <id>build-launchpad-package</id>
                         <goals>
-                            <goal>copy-dependencies</goal>
+                            <goal>package</goal>
                         </goals>
-                            <phase>process-resources</phase>
+                        <phase>pre-integration-test</phase>
                         <configuration>
-                            <includeArtifactIds>org.apache.sling.launchpad</includeArtifactIds>
-                            <excludeTransitive>true</excludeTransitive>
-                            <overWriteReleases>false</overWriteReleases>
-                            <overWriteSnapshots>false</overWriteSnapshots>
+                            <attachArtifact>false</attachArtifact>
                         </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>
+                        <id>start-container-before-IT</id>
                         <goals>
-                            <goal>copy-dependencies</goal>
+                            <goal>start</goal>
                         </goals>
-                            <phase>process-resources</phase>
                         <configuration>
-                            <outputDirectory>${project.build.directory}</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>
+                        <id>stop-container-after-IT</id>
                         <goals>
-                            <goal>reserve-network-port</goal>
+                            <goal>stop</goal>
                         </goals>
-                        <phase>process-resources</phase>
                         <configuration>
-                            <portNames>
-                                <portName>http.port</portName>
-                            </portNames>
+                            <shouldBlockUntilKeyIsPressed>${keepITServerRunning}</shouldBlockUntilKeyIsPressed>
                         </configuration>
                     </execution>
                 </executions>
+                <configuration>
+                    <servers>
+                        <!-- this configuration applies to both 'start' and 'stop' -->
+                        <server>
+                            <id>singleinstance</id>
+                            <port>${http.port}</port>
+                            <vmOpts>${sling.vm.options}</vmOpts>
+                            <stdOutFile>sling/logs/stdout.log</stdOutFile>
+                        </server>
+                    </servers>
+                    <!-- this configuration only applies to 'prepare-package' and 'package' -->
+                    <disableExtendingMavenClasspath>true</disableExtendingMavenClasspath>
+                    <usePomDependencies>true</usePomDependencies>
+                </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>
+                        <configuration>
+                            <systemProperties>
+                                <http.port>${http.port}</http.port>
+                            </systemProperties>
+                        </configuration>
                     </execution>
                 </executions>
                 <configuration>
-                    <debugForkedProcess>${maven.surefire.debug}</debugForkedProcess>
                     <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,${project.basedir}/target/sling/additional-bundles</additional.bundles.path>
-                        <keepJarRunning>${keepJarRunning}</keepJarRunning>
+                        <launchpad.http.server.url>http://localhost:${http.port}</launchpad.http.server.url>
                         <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.3>org.apache.sling.commons.johnzon</sling.additional.bundle.3>
-                        <sling.additional.bundle.4>commons-lang3</sling.additional.bundle.4>
-                        <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.jacksonexporter</sling.additional.bundle.12>
-                        <sling.additional.bundle.13>jackson-annotations</sling.additional.bundle.13>
-                        <sling.additional.bundle.14>jackson-core</sling.additional.bundle.14>
-                        <sling.additional.bundle.15>jackson-databind</sling.additional.bundle.15>
-                        <sling.additional.bundle.16>commons-lang3</sling.additional.bundle.16>
-                        <sling.additional.bundle.17>${project.build.finalName}.jar</sling.additional.bundle.17>
+                        <server.ready.path.1>/starter/index.html:Getting Started</server.ready.path.1>
                     </systemPropertyVariables>
                 </configuration>
             </plugin>
@@ -285,43 +181,60 @@
     <dependencies>
         <dependency>
             <groupId>org.osgi</groupId>
-            <artifactId>org.osgi.core</artifactId>
+            <artifactId>osgi.core</artifactId>
             <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>org.osgi</groupId>
-            <artifactId>org.osgi.compendium</artifactId>
+            <artifactId>osgi.cmpn</artifactId>
             <scope>provided</scope>
         </dependency>
+
+        <!-- OSGi annotations -->
+        <dependency>
+            <groupId>org.osgi</groupId>
+            <artifactId>org.osgi.annotation.versioning</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.osgi</groupId>
+            <artifactId>org.osgi.service.component.annotations</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.osgi</groupId>
+            <artifactId>org.osgi.service.metatype.annotations</artifactId>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.sling</groupId>
+            <artifactId>org.apache.sling.servlets.annotations</artifactId>
+            <scope>provided</scope>
+        </dependency>
+
         <!-- 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.26</version>
+            <version>1.0.28</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.testing.rules</artifactId>
-            <version>1.0.1</version>
+            <version>1.0.8</version>
             <scope>test</scope>
         </dependency>
         <dependency>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.junit.teleporter</artifactId>
-            <version>1.0.12</version>
+            <version>1.0.20</version>
             <scope>test</scope>
         </dependency>
         <dependency>
-          <groupId>org.apache.sling</groupId>
-          <artifactId>org.apache.sling.commons.johnzon</artifactId>
-          <version>1.0.0</version>
-          <scope>provided</scope>
-        </dependency>
-        <dependency>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.engine</artifactId>
-            <version>2.2.0</version>
+            <version>2.6.14</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
@@ -333,7 +246,7 @@
         <dependency>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.models.impl</artifactId>
-            <version>1.4.11-SNAPSHOT</version>
+            <version>1.4.17-SNAPSHOT</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
@@ -342,83 +255,58 @@
             <version>1.0.9-SNAPSHOT</version>
             <scope>provided</scope>
         </dependency>
-        <dependency>
-            <groupId>com.fasterxml.jackson.core</groupId>
-            <artifactId>jackson-databind</artifactId>
-            <version>2.3.2</version>
-            <scope>provided</scope>
-        </dependency>
-        <dependency>
-            <groupId>com.fasterxml.jackson.core</groupId>
-            <artifactId>jackson-core</artifactId>
-            <version>2.3.2</version>
-            <scope>provided</scope>
-        </dependency>
-        <dependency>
-            <groupId>com.fasterxml.jackson.core</groupId>
-            <artifactId>jackson-annotations</artifactId>
-            <version>2.3.2</version>
-            <scope>provided</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.commons</groupId>
-            <artifactId>commons-lang3</artifactId>
-            <version>3.4</version>
-            <scope>provided</scope>
-        </dependency>
-
-        <!-- not part of launchpad 7 (see SLING-4710) -->
-        <dependency>
-            <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-atinject_1.0_spec</artifactId>
-            <version>1.0</version>
-            <scope>provided</scope>
-        </dependency>
         
         <!-- actual dependencies -->
         <dependency>
             <groupId>javax.servlet</groupId>
-            <artifactId>servlet-api</artifactId>
+            <artifactId>javax.servlet-api</artifactId>
             <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>javax.jcr</groupId>
             <artifactId>jcr</artifactId>
+            <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>org.apache.sling</groupId>
             <artifactId>org.apache.sling.api</artifactId>
-            <version>2.4.0</version>
+            <version>2.18.4</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
-            <groupId>commons-lang</groupId>
-            <artifactId>commons-lang</artifactId>
-            <version>2.5</version>
+            <groupId>org.apache.commons</groupId>
+            <artifactId>commons-lang3</artifactId>
+            <version>3.8.1</version>
             <scope>provided</scope>
         </dependency>
         <dependency>
-            <groupId>org.apache.sling</groupId>
-            <artifactId>org.apache.sling.launchpad</artifactId>
-            <version>8</version>
+            <groupId>com.fasterxml.jackson.core</groupId>
+            <artifactId>jackson-annotations</artifactId>
+            <version>2.9.7</version>
+            <scope>provided</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-atinject_1.0_spec</artifactId>
+            <version>1.0</version>
+            <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-api</artifactId>
-            <version>1.6.6</version>
+            <scope>provided</scope>
         </dependency>
         <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-simple</artifactId>
             <scope>test</scope>
-            <version>1.6.6</version>
         </dependency>
         <dependency>
             <groupId>junit</groupId>
             <artifactId>junit</artifactId>
-            <version>4.12</version>
             <scope>test</scope>
         </dependency>
+        <!-- This dependency is not actually used within Sling. It's used for ModelWithOptionalImport test case to test a model with a class that is not resolved. -->
         <dependency>
             <groupId>commons-beanutils</groupId>
             <artifactId>commons-beanutils</artifactId>
@@ -426,6 +314,7 @@
             <scope>provided</scope>
         </dependency>
     </dependencies>
+
     <profiles>
         <profile>
             <id>debug-remote-process</id>
@@ -440,4 +329,5 @@
             </properties>
         </profile>
     </profiles>
+
 </project>
diff --git a/src/main/java/org/apache/sling/models/it/delegate/request/DelegateBaseModel.java b/src/main/java/org/apache/sling/models/it/delegate/request/DelegateBaseModel.java
index e958123..db9f00f 100644
--- a/src/main/java/org/apache/sling/models/it/delegate/request/DelegateBaseModel.java
+++ b/src/main/java/org/apache/sling/models/it/delegate/request/DelegateBaseModel.java
@@ -16,12 +16,12 @@
  */
 package org.apache.sling.models.it.delegate.request;
 
+import javax.inject.Inject;
+
 import org.apache.sling.api.SlingHttpServletRequest;
 import org.apache.sling.models.annotations.Model;
 import org.apache.sling.models.annotations.Via;
 
-import javax.inject.Inject;
-
 @Model(adaptables = SlingHttpServletRequest.class, adapters = DelegateInterface.class,
     resourceType = "sling/delegate/base")
 public class DelegateBaseModel implements DelegateInterface {
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/delegate/request/package-info.java
similarity index 59%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/delegate/request/package-info.java
index f8ccb2d..3e7e701 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/delegate/request/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
+@Version("1.0")
+package org.apache.sling.models.it.delegate.request;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
-
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java b/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java
index d58cf87..476fce6 100644
--- a/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java
+++ b/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java
@@ -16,11 +16,11 @@
  */
 package org.apache.sling.models.it.delegate.resource;
 
+import javax.inject.Inject;
+
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Model;
 
-import javax.inject.Inject;
-
 @Model(adaptables = Resource.class, adapters = DelegateInterface.class,
     resourceType = "sling/delegate/base")
 public class DelegateBaseModel implements DelegateInterface {
diff --git a/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java b/src/main/java/org/apache/sling/models/it/delegate/resource/package-info.java
similarity index 61%
copy from src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java
copy to src/main/java/org/apache/sling/models/it/delegate/resource/package-info.java
index d58cf87..a0f5c5b 100644
--- a/src/main/java/org/apache/sling/models/it/delegate/resource/DelegateBaseModel.java
+++ b/src/main/java/org/apache/sling/models/it/delegate/resource/package-info.java
@@ -14,30 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.delegate.resource;
-
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-
-import javax.inject.Inject;
-
-@Model(adaptables = Resource.class, adapters = DelegateInterface.class,
-    resourceType = "sling/delegate/base")
-public class DelegateBaseModel implements DelegateInterface {
 
-    @Inject
-    private String text;
-
-    @Inject
-    private String other;
-
-    @Override
-    public String getText() {
-        return text;
-    }
+@Version("1.0")
+package org.apache.sling.models.it.delegate.resource;
 
-    @Override
-    public String getOther() {
-        return other;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/exporter/BaseComponent.java b/src/main/java/org/apache/sling/models/it/exporter/BaseComponent.java
index 26a303b..5412d52 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/BaseComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/BaseComponent.java
@@ -20,7 +20,6 @@ import javax.inject.Inject;
 
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
-import org.apache.sling.models.annotations.ExporterOption;
 import org.apache.sling.models.annotations.Model;
 
 import com.fasterxml.jackson.annotation.JsonProperty;
diff --git a/src/main/java/org/apache/sling/models/it/exporter/BaseRequestComponent.java b/src/main/java/org/apache/sling/models/it/exporter/BaseRequestComponent.java
index 4765b80..95f0547 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/BaseRequestComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/BaseRequestComponent.java
@@ -16,7 +16,12 @@
  */
 package org.apache.sling.models.it.exporter;
 
-import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.Map;
+
+import javax.inject.Inject;
+import javax.servlet.ServletRequest;
+import javax.servlet.http.HttpServletRequest;
+
 import org.apache.sling.api.SlingHttpServletRequest;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
@@ -25,10 +30,7 @@ import org.apache.sling.models.annotations.Model;
 import org.apache.sling.models.annotations.Via;
 import org.apache.sling.models.annotations.injectorspecific.SlingObject;
 
-import javax.inject.Inject;
-import javax.servlet.ServletRequest;
-import javax.servlet.http.HttpServletRequest;
-import java.util.Map;
+import com.fasterxml.jackson.annotation.JsonProperty;
 
 @Model(adaptables = { SlingHttpServletRequest.class }, resourceType = "sling/exp-request/base")
 @Exporter(name = "jackson", extensions = "json", options = {
diff --git a/src/main/java/org/apache/sling/models/it/exporter/ComponentImpl.java b/src/main/java/org/apache/sling/models/it/exporter/ComponentImpl.java
index b5839b8..752efc1 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/ComponentImpl.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/ComponentImpl.java
@@ -16,12 +16,12 @@
  */
 package org.apache.sling.models.it.exporter;
 
+import javax.inject.Inject;
+
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
 import org.apache.sling.models.annotations.Model;
 
-import javax.inject.Inject;
-
 @Model(adaptables = { Resource.class }, adapters = Component.class, resourceType = "sling/exp/interface")
 @Exporter(name = "jackson", extensions = "json")
 public class ComponentImpl implements Component {
diff --git a/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java b/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java
index e7cb909..6a138cc 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java
@@ -16,14 +16,10 @@
  */
 package org.apache.sling.models.it.exporter;
 
-import com.fasterxml.jackson.annotation.JsonProperty;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
 import org.apache.sling.models.annotations.Model;
 
-import javax.inject.Inject;
-import javax.inject.Named;
-
 @Model(adaptables = { Resource.class }, resourceType = "sling/exp/doubled")
 @Exporter(name = "jackson", extensions = "json", selector = "firstmodel")
 public class DoubledFirstComponent {
diff --git a/src/main/java/org/apache/sling/models/it/exporter/ExtendedComponent.java b/src/main/java/org/apache/sling/models/it/exporter/ExtendedComponent.java
index 033a6f6..eb94e7f 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/ExtendedComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/ExtendedComponent.java
@@ -20,12 +20,12 @@ import java.util.Calendar;
 import java.util.Date;
 import java.util.GregorianCalendar;
 
+import javax.inject.Inject;
+
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
 import org.apache.sling.models.annotations.Model;
 
-import javax.inject.Inject;
-
 @Model(adaptables = { Resource.class }, resourceType = "sling/exp/extended")
 @Exporter(name = "jackson", extensions = "json")
 public class ExtendedComponent extends BaseComponent {
diff --git a/src/main/java/org/apache/sling/models/it/exporter/ExtendedRequestComponent.java b/src/main/java/org/apache/sling/models/it/exporter/ExtendedRequestComponent.java
index 6231d68..4072497 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/ExtendedRequestComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/ExtendedRequestComponent.java
@@ -16,18 +16,18 @@
  */
 package org.apache.sling.models.it.exporter;
 
+import java.util.Calendar;
+import java.util.Date;
+import java.util.GregorianCalendar;
+
+import javax.inject.Inject;
+
 import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
 import org.apache.sling.models.annotations.ExporterOption;
 import org.apache.sling.models.annotations.Model;
 import org.apache.sling.models.annotations.Via;
 
-import javax.inject.Inject;
-import java.util.Calendar;
-import java.util.Date;
-import java.util.GregorianCalendar;
-
 @Model(adaptables = { SlingHttpServletRequest.class }, resourceType = "sling/exp-request/extended")
 @Exporter(name = "jackson", extensions = "json", options = {
     @ExporterOption(name = "SerializationFeature.WRITE_DATES_AS_TIMESTAMPS", value = "false")
diff --git a/src/main/java/org/apache/sling/models/it/exporter/RequestComponentImpl.java b/src/main/java/org/apache/sling/models/it/exporter/RequestComponentImpl.java
index 7872b75..34c8c49 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/RequestComponentImpl.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/RequestComponentImpl.java
@@ -16,6 +16,8 @@
  */
 package org.apache.sling.models.it.exporter;
 
+import javax.inject.Inject;
+
 import org.apache.sling.api.SlingHttpServletRequest;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Exporter;
@@ -23,8 +25,6 @@ import org.apache.sling.models.annotations.Model;
 import org.apache.sling.models.annotations.Via;
 import org.apache.sling.models.annotations.injectorspecific.SlingObject;
 
-import javax.inject.Inject;
-
 @Model(adaptables = { SlingHttpServletRequest.class }, adapters = Component.class, resourceType = "sling/exp-request/interface")
 @Exporter(name = "jackson", extensions = "json")
 public class RequestComponentImpl implements Component {
diff --git a/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java b/src/main/java/org/apache/sling/models/it/exporter/package-info.java
similarity index 62%
copy from src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java
copy to src/main/java/org/apache/sling/models/it/exporter/package-info.java
index e7cb909..d6273ab 100644
--- a/src/main/java/org/apache/sling/models/it/exporter/DoubledFirstComponent.java
+++ b/src/main/java/org/apache/sling/models/it/exporter/package-info.java
@@ -14,21 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.exporter;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Exporter;
-import org.apache.sling.models.annotations.Model;
 
-import javax.inject.Inject;
-import javax.inject.Named;
-
-@Model(adaptables = { Resource.class }, resourceType = "sling/exp/doubled")
-@Exporter(name = "jackson", extensions = "json", selector = "firstmodel")
-public class DoubledFirstComponent {
+@Version("1.0")
+package org.apache.sling.models.it.exporter;
 
-    public String getValue() {
-        return "first";
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/implpicker/CustomLastImplementationPicker.java b/src/main/java/org/apache/sling/models/it/implpicker/CustomLastImplementationPicker.java
index e7565b2..650e204 100644
--- a/src/main/java/org/apache/sling/models/it/implpicker/CustomLastImplementationPicker.java
+++ b/src/main/java/org/apache/sling/models/it/implpicker/CustomLastImplementationPicker.java
@@ -18,23 +18,20 @@
  */
 package org.apache.sling.models.it.implpicker;
 
-import org.apache.commons.lang.StringUtils;
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Property;
-import org.apache.felix.scr.annotations.Service;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.spi.ImplementationPicker;
-import org.osgi.framework.Constants;
+import org.osgi.service.component.annotations.Component;
+import org.osgi.service.component.propertytypes.ServiceRanking;
 
 /**
  * This is a curious {@link ImplementationPicker} implementation for integration test
  * that picks the last implementation if the resource has the name "custom";
  */
-@Component
-@Service
-@Property(name = Constants.SERVICE_RANKING, intValue = 100)
+@Component(service = ImplementationPicker.class)
+@ServiceRanking(100)
 public class CustomLastImplementationPicker implements ImplementationPicker {
-    
+
     public static final String CUSTOM_NAME = "custom";
 
     public Class<?> pick(Class<?> adapterType, Class<?>[] implementationsTypes, Object adaptable) {
@@ -43,5 +40,5 @@ public class CustomLastImplementationPicker implements ImplementationPicker {
         }
         return null;
     }
-    
+
 }
\ No newline at end of file
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/implpicker/package-info.java
similarity index 59%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/implpicker/package-info.java
index f8ccb2d..c8a5b3e 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/implpicker/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
+@Version("1.0")
+package org.apache.sling.models.it.implpicker;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
-
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
index f8ccb2d..5c6bf58 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
@@ -17,7 +17,6 @@
 package org.apache.sling.models.it.models;
 
 import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
 import org.apache.sling.models.annotations.Model;
 import org.apache.sling.models.annotations.injectorspecific.Self;
 
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/models/implextend/package-info.java
similarity index 59%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/models/implextend/package-info.java
index f8ccb2d..3d4840c 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/models/implextend/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
+@Version("1.0")
+package org.apache.sling.models.it.models.implextend;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
-
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/models/package-info.java
similarity index 62%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/models/package-info.java
index f8ccb2d..d387b59 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/models/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
-
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
+@Version("1.0")
+package org.apache.sling.models.it.models;
 
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/rtbound/package-info.java
similarity index 59%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/rtbound/package-info.java
index f8ccb2d..19332e3 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/rtbound/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
+@Version("1.0")
+package org.apache.sling.models.it.rtbound;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
-
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java b/src/main/java/org/apache/sling/models/it/rtboundpicker/package-info.java
similarity index 59%
copy from src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
copy to src/main/java/org/apache/sling/models/it/rtboundpicker/package-info.java
index f8ccb2d..950815c 100644
--- a/src/main/java/org/apache/sling/models/it/models/RequestSelfModelImpl.java
+++ b/src/main/java/org/apache/sling/models/it/rtboundpicker/package-info.java
@@ -14,20 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.models;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.models.annotations.Model;
-import org.apache.sling.models.annotations.injectorspecific.Self;
+@Version("1.0")
+package org.apache.sling.models.it.rtboundpicker;
 
-@Model(adaptables = SlingHttpServletRequest.class, adapters = RequestSelfModel.class)
-public class RequestSelfModelImpl implements RequestSelfModel {
-
-    @Self
-    private SlingHttpServletRequest request;
-
-    public SlingHttpServletRequest getRequest() {
-        return request;
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/services/AnotherTestBindingsValuesProvider.java b/src/main/java/org/apache/sling/models/it/services/AnotherTestBindingsValuesProvider.java
index ee77a9c..261f427 100644
--- a/src/main/java/org/apache/sling/models/it/services/AnotherTestBindingsValuesProvider.java
+++ b/src/main/java/org/apache/sling/models/it/services/AnotherTestBindingsValuesProvider.java
@@ -16,20 +16,20 @@
  */
 package org.apache.sling.models.it.services;
 
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Property;
-import org.apache.felix.scr.annotations.Service;
-
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.Map;
 
-@Component
-@Service(value = Map.class)
-@Property(name = "javax.script.name", value = "sling-models-exporter")
+import org.osgi.service.component.annotations.Component;
+
+@Component(service = Map.class, property = {
+    "javax.script.name=sling-models-exporter"
+})
 public class AnotherTestBindingsValuesProvider extends HashMap<String, Object> {
+    private static final long serialVersionUID = 1L;
 
     public AnotherTestBindingsValuesProvider() {
         super.put("testBindingsObject2", Collections.singletonMap("name2", "value2"));
     }
+
 }
diff --git a/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java b/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java
index 40ee96a..e49e2d3 100644
--- a/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java
+++ b/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java
@@ -16,17 +16,15 @@
  */
 package org.apache.sling.models.it.services;
 
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Property;
-import org.apache.felix.scr.annotations.Service;
-
 import java.util.Collections;
 import java.util.HashMap;
 import java.util.Map;
 
-@Component
-@Service(value = Map.class)
-@Property(name = "javax.script.name", value = "*")
+import org.osgi.service.component.annotations.Component;
+
+@Component(service = Map.class, property = {
+    "javax.script.name=*"
+})
 public class TestBindingsValuesProvider extends HashMap<String, Object> {
 
     public TestBindingsValuesProvider() {
diff --git a/src/main/java/org/apache/sling/models/it/services/TestResourceDecorator.java b/src/main/java/org/apache/sling/models/it/services/TestResourceDecorator.java
index 503ca5b..d615a3a 100644
--- a/src/main/java/org/apache/sling/models/it/services/TestResourceDecorator.java
+++ b/src/main/java/org/apache/sling/models/it/services/TestResourceDecorator.java
@@ -16,19 +16,17 @@
  */
 package org.apache.sling.models.it.services;
 
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Reference;
-import org.apache.felix.scr.annotations.Service;
+import javax.servlet.http.HttpServletRequest;
+
 import org.apache.sling.api.adapter.AdapterManager;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceDecorator;
 import org.apache.sling.api.resource.ResourceWrapper;
 import org.apache.sling.api.resource.ValueMap;
+import org.osgi.service.component.annotations.Component;
+import org.osgi.service.component.annotations.Reference;
 
-import javax.servlet.http.HttpServletRequest;
-
-@Component
-@Service
+@Component(service = ResourceDecorator.class)
 public class TestResourceDecorator implements ResourceDecorator {
 
     @Reference
diff --git a/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java b/src/main/java/org/apache/sling/models/it/services/package-info.java
similarity index 61%
copy from src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java
copy to src/main/java/org/apache/sling/models/it/services/package-info.java
index 40ee96a..1f5740a 100644
--- a/src/main/java/org/apache/sling/models/it/services/TestBindingsValuesProvider.java
+++ b/src/main/java/org/apache/sling/models/it/services/package-info.java
@@ -14,22 +14,8 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-package org.apache.sling.models.it.services;
-
-import org.apache.felix.scr.annotations.Component;
-import org.apache.felix.scr.annotations.Property;
-import org.apache.felix.scr.annotations.Service;
 
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Map;
-
-@Component
-@Service(value = Map.class)
-@Property(name = "javax.script.name", value = "*")
-public class TestBindingsValuesProvider extends HashMap<String, Object> {
+@Version("1.0")
+package org.apache.sling.models.it.services;
 
-    public TestBindingsValuesProvider() {
-        super.put("testBindingsObject", Collections.singletonMap("name", "value"));
-    }
-}
+import org.osgi.annotation.versioning.Version;
diff --git a/src/main/java/org/apache/sling/models/it/servlets/PathBoundServlet.java b/src/main/java/org/apache/sling/models/it/servlets/PathBoundServlet.java
index 170d7f3..18c4209 100644
--- a/src/main/java/org/apache/sling/models/it/servlets/PathBoundServlet.java
+++ b/src/main/java/org/apache/sling/models/it/servlets/PathBoundServlet.java
@@ -16,16 +16,20 @@
  */
 package org.apache.sling.models.it.servlets;
 
-import org.apache.felix.scr.annotations.sling.SlingServlet;
+import java.io.IOException;
+
+import javax.servlet.Servlet;
+import javax.servlet.ServletException;
+
 import org.apache.sling.api.SlingHttpServletRequest;
 import org.apache.sling.api.SlingHttpServletResponse;
 import org.apache.sling.api.servlets.SlingSafeMethodsServlet;
 import org.apache.sling.models.it.models.RequestSelfModel;
+import org.apache.sling.servlets.annotations.SlingServletPaths;
+import org.osgi.service.component.annotations.Component;
 
-import javax.servlet.ServletException;
-import java.io.IOException;
-
-@SlingServlet(paths = "/apps/rtpickerrequest")
+@Component(service = Servlet.class)
+@SlingServletPaths("/apps/rtpickerrequest")
 public class PathBoundServlet extends SlingSafeMethodsServlet {
 
     @Override
@@ -33,4 +37,5 @@ public class PathBoundServlet extends SlingSafeMethodsServlet {
         RequestSelfModel model = request.adaptTo(RequestSelfModel.class);
         response.setStatus(200);
     }
+
 }
diff --git a/src/test/java/org/apache/sling/junit/teleporter/customizers/SM_TeleporterCustomizer.java b/src/test/java/org/apache/sling/junit/teleporter/customizers/SM_TeleporterCustomizer.java
index 908be63..0af6245 100644
--- a/src/test/java/org/apache/sling/junit/teleporter/customizers/SM_TeleporterCustomizer.java
+++ b/src/test/java/org/apache/sling/junit/teleporter/customizers/SM_TeleporterCustomizer.java
@@ -21,8 +21,6 @@ import org.apache.sling.testing.clients.util.TimeoutsProvider;
 import org.apache.sling.testing.serversetup.instance.SlingTestBase;
 import org.apache.sling.testing.teleporter.client.ClientSideTeleporter;
 
-import java.io.File;
-
 /** This is required by the TeleporterRule, to setup the client-side
  *  teleporter with (at least) the test server URL.
  */
diff --git a/src/test/java/org/apache/sling/models/testing/DecoratedIT.java b/src/test/java/org/apache/sling/models/testing/DecoratedIT.java
index 54ee904..a726c9e 100644
--- a/src/test/java/org/apache/sling/models/testing/DecoratedIT.java
+++ b/src/test/java/org/apache/sling/models/testing/DecoratedIT.java
@@ -16,7 +16,13 @@
  */
 package org.apache.sling.models.testing;
 
-import org.apache.commons.lang.RandomStringUtils;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import javax.jcr.Node;
+import javax.jcr.Session;
+
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
 import org.apache.sling.api.resource.ResourceResolverFactory;
@@ -29,11 +35,6 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 
-import javax.jcr.Node;
-import javax.jcr.Session;
-
-import static org.junit.Assert.*;
-
 public class DecoratedIT {
 
     @Rule
diff --git a/src/test/java/org/apache/sling/models/testing/ImplementsExtendsIT.java b/src/test/java/org/apache/sling/models/testing/ImplementsExtendsIT.java
index a26b21b..c794f69 100644
--- a/src/test/java/org/apache/sling/models/testing/ImplementsExtendsIT.java
+++ b/src/test/java/org/apache/sling/models/testing/ImplementsExtendsIT.java
@@ -24,7 +24,7 @@ import javax.jcr.Node;
 import javax.jcr.RepositoryException;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.adapter.AdapterManager;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
diff --git a/src/test/java/org/apache/sling/models/testing/InjectorSpecificAnnotationIT.java b/src/test/java/org/apache/sling/models/testing/InjectorSpecificAnnotationIT.java
index 7376b81..75acb99 100644
--- a/src/test/java/org/apache/sling/models/testing/InjectorSpecificAnnotationIT.java
+++ b/src/test/java/org/apache/sling/models/testing/InjectorSpecificAnnotationIT.java
@@ -22,7 +22,7 @@ import static org.junit.Assert.assertNotNull;
 import javax.jcr.Node;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
 import org.apache.sling.api.resource.ResourceResolverFactory;
@@ -30,7 +30,6 @@ import org.apache.sling.junit.rules.TeleporterRule;
 import org.apache.sling.models.it.models.SlingPropertyAnnotationTestModel;
 import org.junit.Rule;
 import org.junit.Test;
-import org.junit.runner.RunWith;
 
 public class InjectorSpecificAnnotationIT {
 
diff --git a/src/test/java/org/apache/sling/models/testing/ModelFactorySimpleIT.java b/src/test/java/org/apache/sling/models/testing/ModelFactorySimpleIT.java
index 7e5217c..1d21526 100644
--- a/src/test/java/org/apache/sling/models/testing/ModelFactorySimpleIT.java
+++ b/src/test/java/org/apache/sling/models/testing/ModelFactorySimpleIT.java
@@ -25,7 +25,7 @@ import static org.junit.Assert.assertTrue;
 import javax.jcr.Node;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
 import org.apache.sling.api.resource.ResourceResolverFactory;
diff --git a/src/test/java/org/apache/sling/models/testing/ServiceInjectionWithDifferentRankingIT.java b/src/test/java/org/apache/sling/models/testing/ServiceInjectionWithDifferentRankingIT.java
index a1baca3..db3ad99 100644
--- a/src/test/java/org/apache/sling/models/testing/ServiceInjectionWithDifferentRankingIT.java
+++ b/src/test/java/org/apache/sling/models/testing/ServiceInjectionWithDifferentRankingIT.java
@@ -29,7 +29,7 @@ import java.util.Hashtable;
 import javax.jcr.Node;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
 import org.apache.sling.api.resource.ResourceResolverFactory;
diff --git a/src/test/java/org/apache/sling/models/testing/SimpleIT.java b/src/test/java/org/apache/sling/models/testing/SimpleIT.java
index ee8030f..1aef27e 100644
--- a/src/test/java/org/apache/sling/models/testing/SimpleIT.java
+++ b/src/test/java/org/apache/sling/models/testing/SimpleIT.java
@@ -16,19 +16,21 @@
  */
 package org.apache.sling.models.testing;
 
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertSame;
 
 import javax.jcr.Node;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.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.rules.TeleporterRule;
 import org.apache.sling.models.it.models.ConstructorInjectionTestModel;
-import org.apache.sling.models.it.models.InterfaceInjectionTestModel;
 import org.apache.sling.models.it.models.FieldInjectionTestModel;
+import org.apache.sling.models.it.models.InterfaceInjectionTestModel;
 import org.junit.After;
 import org.junit.Before;
 import org.junit.Rule;
diff --git a/src/test/java/org/apache/sling/models/testing/ViaIT.java b/src/test/java/org/apache/sling/models/testing/ViaIT.java
index b450154..ac63b9e 100644
--- a/src/test/java/org/apache/sling/models/testing/ViaIT.java
+++ b/src/test/java/org/apache/sling/models/testing/ViaIT.java
@@ -16,12 +16,13 @@
  */
 package org.apache.sling.models.testing;
 
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
 
 import javax.jcr.Node;
 import javax.jcr.Session;
 
-import org.apache.commons.lang.RandomStringUtils;
+import org.apache.commons.lang3.RandomStringUtils;
 import org.apache.sling.api.adapter.AdapterManager;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
diff --git a/src/test/java/org/apache/sling/models/testing/delegate/DelegateRequestIT.java b/src/test/java/org/apache/sling/models/testing/delegate/DelegateRequestIT.java
index 1f4e04a..0cb831f 100644
--- a/src/test/java/org/apache/sling/models/testing/delegate/DelegateRequestIT.java
+++ b/src/test/java/org/apache/sling/models/testing/delegate/DelegateRequestIT.java
@@ -16,6 +16,13 @@
  */
 package org.apache.sling.models.testing.delegate;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.util.HashMap;
+import java.util.Map;
+
 import org.apache.sling.api.SlingConstants;
 import org.apache.sling.api.resource.LoginException;
 import org.apache.sling.api.resource.PersistenceException;
@@ -33,11 +40,6 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 
-import java.util.HashMap;
-import java.util.Map;
-
-import static org.junit.Assert.*;
-
 public class DelegateRequestIT {
 
     @Rule
diff --git a/src/test/java/org/apache/sling/models/testing/delegate/DelegateResourceIT.java b/src/test/java/org/apache/sling/models/testing/delegate/DelegateResourceIT.java
index 044d98a..60b7e2d 100644
--- a/src/test/java/org/apache/sling/models/testing/delegate/DelegateResourceIT.java
+++ b/src/test/java/org/apache/sling/models/testing/delegate/DelegateResourceIT.java
@@ -16,6 +16,13 @@
  */
 package org.apache.sling.models.testing.delegate;
 
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.util.HashMap;
+import java.util.Map;
+
 import org.apache.sling.api.SlingConstants;
 import org.apache.sling.api.resource.LoginException;
 import org.apache.sling.api.resource.PersistenceException;
@@ -31,11 +38,6 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 
-import java.util.HashMap;
-import java.util.Map;
-
-import static org.junit.Assert.*;
-
 public class DelegateResourceIT {
 
     @Rule
diff --git a/src/test/java/org/apache/sling/models/testing/exporter/ExporterIT.java b/src/test/java/org/apache/sling/models/testing/exporter/ExporterIT.java
index 5221f31..dacb061 100644
--- a/src/test/java/org/apache/sling/models/testing/exporter/ExporterIT.java
+++ b/src/test/java/org/apache/sling/models/testing/exporter/ExporterIT.java
@@ -16,9 +16,9 @@
  */
 package org.apache.sling.models.testing.exporter;
 
+import java.io.ByteArrayInputStream;
 import java.io.InputStream;
 import java.io.StringReader;
-import java.io.ByteArrayInputStream;
 import java.text.Format;
 import java.util.Calendar;
 import java.util.Collections;
@@ -29,8 +29,8 @@ import java.util.TimeZone;
 import javax.json.Json;
 import javax.json.JsonObject;
 
-import org.apache.commons.lang.StringUtils;
-import org.apache.commons.lang.time.FastDateFormat;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.time.FastDateFormat;
 import org.apache.sling.api.SlingConstants;
 import org.apache.sling.api.resource.Resource;
 import org.apache.sling.api.resource.ResourceResolver;
@@ -68,7 +68,7 @@ public class ExporterIT {
     private final String interfaceRequestComponentPath = "/content/exp-request/interfaceComponent";
     private Calendar testDate;
 
-    private Format dateFormat = FastDateFormat.getInstance("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
+    private Format dateFormat = FastDateFormat.getInstance("yyyy-MM-dd'T'HH:mm:ss.SSSZ", TimeZone.getTimeZone("UTC"));
 
     @Before
     public void setup() throws Exception {
diff --git a/src/test/java/org/apache/sling/models/testing/helper/FakeRequest.java b/src/test/java/org/apache/sling/models/testing/helper/FakeRequest.java
index 935f706..4e1d969 100644
--- a/src/test/java/org/apache/sling/models/testing/helper/FakeRequest.java
+++ b/src/test/java/org/apache/sling/models/testing/helper/FakeRequest.java
@@ -16,21 +16,32 @@
  */
 package org.apache.sling.models.testing.helper;
 
-import javax.servlet.RequestDispatcher;
-import javax.servlet.ServletInputStream;
-import javax.servlet.http.Cookie;
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpSession;
 import java.io.BufferedReader;
 import java.io.IOException;
 import java.io.UnsupportedEncodingException;
 import java.security.Principal;
+import java.util.Collection;
 import java.util.Collections;
 import java.util.Enumeration;
 import java.util.HashMap;
 import java.util.Locale;
 import java.util.Map;
 
+import javax.servlet.AsyncContext;
+import javax.servlet.DispatcherType;
+import javax.servlet.RequestDispatcher;
+import javax.servlet.ServletContext;
+import javax.servlet.ServletException;
+import javax.servlet.ServletInputStream;
+import javax.servlet.ServletRequest;
+import javax.servlet.ServletResponse;
+import javax.servlet.http.Cookie;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
+import javax.servlet.http.HttpUpgradeHandler;
+import javax.servlet.http.Part;
+
 public class FakeRequest implements HttpServletRequest {
 
     private final String path;
@@ -313,4 +324,80 @@ public class FakeRequest implements HttpServletRequest {
     public int getLocalPort() {
         return 0;
     }
+
+    @Override
+    public long getContentLengthLong() {
+        return 0;
+    }
+
+    @Override
+    public ServletContext getServletContext() {
+        return null;
+    }
+
+    @Override
+    public AsyncContext startAsync() throws IllegalStateException {
+        return null;
+    }
+
+    @Override
+    public AsyncContext startAsync(ServletRequest servletRequest, ServletResponse servletResponse)
+            throws IllegalStateException {
+        return null;
+    }
+
+    @Override
+    public boolean isAsyncStarted() {
+        return false;
+    }
+
+    @Override
+    public boolean isAsyncSupported() {
+        return false;
+    }
+
+    @Override
+    public AsyncContext getAsyncContext() {
+        return null;
+    }
+
+    @Override
+    public DispatcherType getDispatcherType() {
+        return null;
+    }
+
+    @Override
+    public String changeSessionId() {
+        return null;
+    }
+
+    @Override
+    public boolean authenticate(HttpServletResponse response) throws IOException, ServletException {
+        return false;
+    }
+
+    @Override
+    public void login(String username, String password) throws ServletException {
+
+    }
+
+    @Override
+    public void logout() throws ServletException {
+
+    }
+
+    @Override
+    public Collection<Part> getParts() throws IOException, ServletException {
+        return null;
+    }
+
+    @Override
+    public Part getPart(String name) throws IOException, ServletException {
+        return null;
+    }
+
+    @Override
+    public <T extends HttpUpgradeHandler> T upgrade(Class<T> handlerClass) throws IOException, ServletException {
+        return null;
+    }
 }
\ No newline at end of file
diff --git a/src/test/java/org/apache/sling/models/testing/helper/FakeResponse.java b/src/test/java/org/apache/sling/models/testing/helper/FakeResponse.java
index 7cf757a..43f8b64 100644
--- a/src/test/java/org/apache/sling/models/testing/helper/FakeResponse.java
+++ b/src/test/java/org/apache/sling/models/testing/helper/FakeResponse.java
@@ -16,14 +16,16 @@
  */
 package org.apache.sling.models.testing.helper;
 
-import javax.servlet.ServletOutputStream;
-import javax.servlet.http.Cookie;
-import javax.servlet.http.HttpServletResponse;
 import java.io.IOException;
 import java.io.PrintWriter;
 import java.io.StringWriter;
+import java.util.Collection;
 import java.util.Locale;
 
+import javax.servlet.ServletOutputStream;
+import javax.servlet.http.Cookie;
+import javax.servlet.http.HttpServletResponse;
+
 public class FakeResponse implements HttpServletResponse {
 
     private StringWriter stringWriter = new StringWriter();
@@ -197,4 +199,24 @@ public class FakeResponse implements HttpServletResponse {
     public int getStatus() {
         return status;
     }
+
+    @Override
+    public void setContentLengthLong(long len) {
+
+    }
+
+    @Override
+    public String getHeader(String name) {
+        return null;
+    }
+
+    @Override
+    public Collection<String> getHeaders(String name) {
+        return null;
+    }
+
+    @Override
+    public Collection<String> getHeaderNames() {
+        return null;
+    }
 }
diff --git a/src/test/java/org/apache/sling/models/testing/rtbound/FakeRequest.java b/src/test/java/org/apache/sling/models/testing/rtbound/FakeRequest.java
index e4f0c04..6548ac9 100644
--- a/src/test/java/org/apache/sling/models/testing/rtbound/FakeRequest.java
+++ b/src/test/java/org/apache/sling/models/testing/rtbound/FakeRequest.java
@@ -16,28 +16,40 @@
  */
 package org.apache.sling.models.testing.rtbound;
 
-import org.apache.sling.api.SlingHttpServletRequest;
-import org.apache.sling.api.request.RequestDispatcherOptions;
-import org.apache.sling.api.request.RequestParameter;
-import org.apache.sling.api.request.RequestParameterMap;
-import org.apache.sling.api.request.RequestPathInfo;
-import org.apache.sling.api.request.RequestProgressTracker;
-import org.apache.sling.api.resource.Resource;
-import org.apache.sling.api.resource.ResourceResolver;
-
-import javax.servlet.RequestDispatcher;
-import javax.servlet.ServletInputStream;
-import javax.servlet.http.Cookie;
-import javax.servlet.http.HttpSession;
 import java.io.BufferedReader;
 import java.io.IOException;
 import java.io.UnsupportedEncodingException;
 import java.security.Principal;
+import java.util.Collection;
 import java.util.Enumeration;
+import java.util.List;
 import java.util.Locale;
 import java.util.Map;
 import java.util.ResourceBundle;
 
+import javax.servlet.AsyncContext;
+import javax.servlet.DispatcherType;
+import javax.servlet.RequestDispatcher;
+import javax.servlet.ServletContext;
+import javax.servlet.ServletException;
+import javax.servlet.ServletInputStream;
+import javax.servlet.ServletRequest;
+import javax.servlet.ServletResponse;
+import javax.servlet.http.Cookie;
+import javax.servlet.http.HttpServletResponse;
+import javax.servlet.http.HttpSession;
+import javax.servlet.http.HttpUpgradeHandler;
+import javax.servlet.http.Part;
+
+import org.apache.sling.api.SlingHttpServletRequest;
+import org.apache.sling.api.request.RequestDispatcherOptions;
+import org.apache.sling.api.request.RequestParameter;
+import org.apache.sling.api.request.RequestParameterMap;
+import org.apache.sling.api.request.RequestPathInfo;
+import org.apache.sling.api.request.RequestProgressTracker;
+import org.apache.sling.api.resource.Resource;
+import org.apache.sling.api.resource.ResourceResolver;
+
 public class FakeRequest implements SlingHttpServletRequest {
 
     private final Resource resource;
@@ -395,4 +407,86 @@ public class FakeRequest implements SlingHttpServletRequest {
     public <AdapterType> AdapterType adaptTo(Class<AdapterType> aClass) {
         return null;
     }
+
+    @Override
+    public String changeSessionId() {
+        return null;
+    }
+
+    @Override
+    public boolean authenticate(HttpServletResponse response) throws IOException, ServletException {
+        return false;
+    }
+
+    @Override
+    public void login(String username, String password) throws ServletException {
+
+    }
+
+    @Override
+    public void logout() throws ServletException {
+
+    }
+
+    @Override
+    public Collection<Part> getParts() throws IOException, ServletException {
+        return null;
+    }
+
+    @Override
+    public Part getPart(String name) throws IOException, ServletException {
+        return null;
+    }
+
+    @Override
+    public <T extends HttpUpgradeHandler> T upgrade(Class<T> handlerClass) throws IOException, ServletException {
+        return null;
+    }
+
+    @Override
+    public long getContentLengthLong() {
+        return 0;
+    }
+
+    @Override
+    public ServletContext getServletContext() {
+        return null;
+    }
+
+    @Override
+    public AsyncContext startAsync() throws IllegalStateException {
+        return null;
+    }
+
+    @Override
+    public AsyncContext startAsync(ServletRequest servletRequest, ServletResponse servletResponse)
+            throws IllegalStateException {
+        return null;
+    }
+
+    @Override
+    public boolean isAsyncStarted() {
+        return false;
+    }
+
+    @Override
+    public boolean isAsyncSupported() {
+        return false;
+    }
+
+    @Override
+    public AsyncContext getAsyncContext() {
+        return null;
+    }
+
+    @Override
+    public DispatcherType getDispatcherType() {
+        return null;
+    }
+
+    @Override
+    public List<RequestParameter> getRequestParameterList() {
+        return null;
+    }
+
 }
diff --git a/src/test/java/org/apache/sling/models/testing/rtboundpicker/ResourceTypePickerIT.java b/src/test/java/org/apache/sling/models/testing/rtboundpicker/ResourceTypePickerIT.java
index 3230d37..d6223ae 100644
--- a/src/test/java/org/apache/sling/models/testing/rtboundpicker/ResourceTypePickerIT.java
+++ b/src/test/java/org/apache/sling/models/testing/rtboundpicker/ResourceTypePickerIT.java
@@ -16,6 +16,9 @@
  */
 package org.apache.sling.models.testing.rtboundpicker;
 
+import java.util.HashMap;
+import java.util.Map;
+
 import org.apache.sling.api.SlingConstants;
 import org.apache.sling.api.resource.LoginException;
 import org.apache.sling.api.resource.PersistenceException;
@@ -32,9 +35,6 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 
-import java.util.HashMap;
-import java.util.Map;
-
 public class ResourceTypePickerIT {
 
     @Rule
diff --git a/src/test/provisioning/sling-models-jacksonexporter.txt b/src/test/provisioning/sling-models-jacksonexporter.txt
new file mode 100644
index 0000000..cf590fa
--- /dev/null
+++ b/src/test/provisioning/sling-models-jacksonexporter.txt
@@ -0,0 +1,24 @@
+#
+#  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.
+#
+
+# must be the same feature name as the feature defined in slingstart to allow merging
+[feature name=models-jacksonexporter]
+
+[artifacts]
+  org.apache.sling/org.apache.sling.models.jacksonexporter
diff --git a/src/test/provisioning/sling.txt b/src/test/provisioning/sling.txt
new file mode 100644
index 0000000..fef1bba
--- /dev/null
+++ b/src/test/provisioning/sling.txt
@@ -0,0 +1,37 @@
+#
+#  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.
+#
+
+# must be the same feature name as the feature defined in slingstart to allow merging
+[feature name=sling]
+
+[artifacts]
+    org.apache.sling/org.apache.sling.starter/11/slingstart
+
+    # Use versions as defined in POM
+    org.apache.sling/org.apache.sling.models.api
+    org.apache.sling/org.apache.sling.models.impl
+
+    # Additional test bundles
+    org.apache.sling/org.apache.sling.junit.core
+    org.apache.sling/org.apache.sling.models.integration-tests
+
+[configurations]
+    # Allow login administrative for org.apache.sling.junit.core
+    org.apache.sling.jcr.base.internal.LoginAdminWhitelist
+        whitelist.bundles.regexp="org\.apache\.sling\.junit\.core"