maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mahesh Bedampeta (JIRA)" <j...@apache.org>
Subject [jira] [Created] (MNG-5985) Need help in executing a Java program and testng.xml one after other using Maven
Date Fri, 26 Feb 2016 05:13:18 GMT
Mahesh Bedampeta created MNG-5985:
-------------------------------------

             Summary: Need help in executing a Java program and testng.xml one after other
using Maven 
                 Key: MNG-5985
                 URL: https://issues.apache.org/jira/browse/MNG-5985
             Project: Maven
          Issue Type: Question
          Components: core
            Reporter: Mahesh Bedampeta
            Priority: Minor


​My question is that I wanted to execute a testNG suite file and a java program one after
other using a POM.xml.

Please help me out with a code snippet that actually does this execution.


Below is my code that is currently running my test scripts of testng.xml, and I want to add
a code for executing a separate Java(Main)​ class. Please add the code for executing my
java program in it.

         <build>
                    <plugins>
                          <plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.17</version>
				<configuration>
					<argLine>
						-javaagent:${settings.localRepository}/org/aspectj/aspectjweaver/${aspectj.version}/aspectjweaver-${aspectj.version}.jar
					</argLine>
						<suiteXmlFiles>
						<suiteXmlFile>${basedir}\testng.xml</suiteXmlFile>
					</suiteXmlFiles>
					<outputDirectory>${basedir}/results</outputDirectory>
				</configuration>
				<dependencies>
					<dependency>
						<groupId>org.aspectj</groupId>
						<artifactId>aspectjweaver</artifactId>
						<version>${aspectj.version}</version>
					</dependency>
				</dependencies>
			</plugin>
		</plugins>
	</build>




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message