Our team is setting up some tests for our AEM code using the TeleporterRule documented at "Apache Sling :: JUnit server-side testing support bundles"
. Our goal currently is to make it easy to set up a test that is able to set the JCR up with specific data, which allows us to make in-depth assertions about service output. We've managed to get tests mostly up and running, but are having trouble sorting out the withResources method. Based on my read of the docs, withResources appears to be intended to provide a mechanism for populating the JCR with data prior to tests being run.
Assuming I construct my test rule like so:
@Rule
public final TeleporterRule teleporter = TeleporterRule.forClass(getClass()).withResources("/test/");
1. Where in the package will the TeleporterRule look when it attempts to load resources from "/test/"?
2. Is there any additional setup needed to get this to work, i.e. adding a filter rule to the package?
3. Does the TeleporterRule automatically clean up any resources that were created in the withResources step?