Many organizations have invested in Maven, Ant and other tools to automate build and test executions. FlexDeploy supports native integration to perform Build and Execute Tests, but it also allows for taking advantage of existing investments in Maven, Ant, etc. In this blog post, I will talk about how to pull in JUnit Test Results from Maven execution, but keep in mind that this option opens up many possibilities for FlexDeploy users.
I will use JUnit Maven Example blog entry to showcase FlexDeploy capabilities.
FlexDeploy executes test cases using Test Definition workflow and as always FlexDeploy workflows are very easy to create with out of box plugins support. In this case, I have created a workflow to execute test phase of maven using Maven plugin. This workflow is associated with FlexDeploy Project similar to build and deploy workflows.
Let’s talk about Build workflow now. For build we will first get source code from SCM which is easy by using SCM-ExportSource workflow which is bundled in FlexDeploy, then run Tests using Invoke Tests operation and at the end run Maven package & capture artifacts.
Now when you execute Build on FlexDeploy Project, you will see Test results on execution screen.
Similar to Maven, Ant can also be used to execute Tests and results can be pulled in to FlexDeploy. If you have other test tools that are not supported out of box by FlexDeploy, you can write your own plugins using FlexDeploy Plugin SDK.