I'm trying to setup an integration tests suite using Atlassian pageobjects.
The plugin on which I'm trying to achieve this depends on the public APIs of other plugins on the marketplace. If I run an instance of JIRA on my local machine, with all plugins installed and in place, and issue a "run tests" from the IDE, the tests run fine. If I atlas-clean the project and try to run atlas-integration-test, my instance loses all the 3rd party plugins my own plugin depends on.
The "home" directory was saved as .zip file and imported as productData, which helps with the environment in which I need to run tests, but doesn't include user installed plugins.
I tried specifying "pluginArtifacts" in the maven-jira-plugin artifactId to match the required plugins' required IDs, but the installation fails.
For instance, if I debug a plugin depending on Portfolio from a clean repository instance, my upm screen shows the Portfolio entries as disabled, and trying to enable them causes a "unable to enable plugin, refer to the log for more details" errors, that in the logs result in a long stacktrace because of the following error:
com.querydsl.sql.types.Type not found by com.radiantminds.roadmaps-jira
Sample plugin Artifacts snippet:
<plugin>
<groupId>com.atlassian.maven.plugins</groupId>
<artifactId>maven-jira-plugin</artifactId>
<configuration>
<productVersion>${jira.version}</productVersion>
<productDataVersion>${jira.version}</productDataVersion>
<productDataPath>${basedir}/src/test/resources/generated-test-resources.zip</productDataPath>
<pluginArtifacts>
<pluginArtifact>
<groupId>com.atlassian</groupId>
<artifactId>portfolio-plugin</artifactId>
<version>2.23.0</version>
</pluginArtifact>
<pluginArtifact>
<groupId>com.atlassian</groupId>
<artifactId>jira-portfolio</artifactId>
<version>2.23.0</version>
</pluginArtifact>
<pluginArtifact>
<groupId>com.atlassian</groupId>
<artifactId>team-management-plugin</artifactId>
<version>2.23.0</version>
</pluginArtifact>
</pluginArtifacts>
...
</configuration
...
</plugin>
We retrieve the artifacts from our internal Maven repository.
I also thought about not depending on these artifacts and just writing a "before any test" class that uses pageobjects to manually navigate in the interface and install Portfolio from upm, but I feel this approach is deeply wrong ;) Also, I couldn't find any relevant answer to this use case on the net. so I'm kind of in the dark.
Ideally I'd want to just run atlas-integration-test in my Bamboo jobs and have the agent autonomously install all dependencies and perform the tests on the same environment I can manually set up up on my local machine.
Is there any way of performing integration tests for plugins depending on other plugins without leaning on containerisation or similar mechanism? What am I doing wrong here?