Executable jar for Quantum Automation Framework

106 views
Skip to first unread message

Shankar Choudhury

unread,
Aug 23, 2019, 12:18:21 AM8/23/19
to qaf users
Hi,

We are using QAF across enterprise.There is a requirement to have an executable jar for entire QAF and the execution should start just with dbl click of the jar file.

Is there a way to package QAF into an executable jar file and run as standalone?

Thanks
Shankar

cjayswal

unread,
Aug 23, 2019, 3:31:47 PM8/23/19
to qaf users
It should be done your project level where you package your test case with all assets along with all dependencies and make executable as you wish.

गुरुवार, 22 अगस्त 2019 को 9:18:21 अपर UTC-7 को, Shankar Choudhury ने लिखा:

saifud...@gmail.com

unread,
Dec 2, 2021, 8:19:09 AM12/2/21
to qaf users
Hello Jayaswal, 

  Following up on old thread.
  Do you have any reference to package QAF into an executable JAR ? 
  Build tool used : Maven
  Framework 3.0.1
  Factory class : BDD2
  Attached the POM file we are using.

Purpose : 
1. Want to deploy the entire framework with dependencies as a Snapshot to be utilized on CICD platforms
2. Execute as a JAR file - To share it with non test Automation team for test execution on local machines.

Thank you.

pom.xml

cjayswal

unread,
Dec 3, 2021, 12:15:48 PM12/3/21
to qaf users
You can use maven-assembly-plugin. You can refer related post. While packaging keep resources and BDD files outside jar so that can be modified if needed without rebuilding the project/jar.

ગુરુવાર, 2 ડિસેમ્બર, 2021ના રોજ 05:19:09 AM UTC-8 વાગ્યે saifud...@gmail.com દ્વારા આમ લખવામાં આવ્યું હતું:

Saifuddin Raj

unread,
Dec 6, 2021, 2:04:43 AM12/6/21
to qaf-...@googlegroups.com
Thank you . Will give this a try.

Sent from my iPhone

On Dec 4, 2021, at 2:15, cjayswal <cjay...@gmail.com> wrote:

You can use maven-assembly-plugin. You can refer related post. While packaging keep resources and BDD files outside jar so that can be modified if needed without rebuilding the project/jar.
--
You received this message because you are subscribed to a topic in the Google Groups "qaf users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/qaf-users/K8mlqod2DPI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to qaf-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/qaf-users/6cc2dd6a-35b0-49d6-9f94-3d6a90691104n%40googlegroups.com.

Wendy Zhang

unread,
Dec 8, 2021, 2:13:41 AM12/8/21
to qaf users
Hi Jayaswal,
 
I was able to pakage everything into a jar but nothing happens after run it through command.
I noticed there is a config for mainClass:
<manifest> <addClasspath>true</addClasspath> <mainClass>fully.qualified.MainClass</mainClass> </manifest>
May I know what's the mainClass we should use to trigger execution?
Looking forward to your reply. Thanks.

Wendy Zhang

unread,
Dec 8, 2021, 4:49:51 AM12/8/21
to qaf users
Hi Jayaswal, 

I got one but not sure if it's correct.
https://github.com/qmetry/qaf/blob/master/src/com/qmetry/qaf/automation/core/QAFTestBase.java#L614
Could you help to confirm and provide some advices?
Thanks.

cjayswal

unread,
Dec 8, 2021, 12:12:54 PM12/8/21
to qaf users
QAFTestBase is not right candidate for MainClass. It can be your custom runner class.
The simplest way is follow the same way as to running testng command line.

બુધવાર, 8 ડિસેમ્બર, 2021ના રોજ 01:49:51 AM UTC-8 વાગ્યે wendy.z...@gmail.com દ્વારા આમ લખવામાં આવ્યું હતું:

Wendy Zhang

unread,
Dec 9, 2021, 2:40:20 AM12/9/21
to qaf users

Hi Jayaswal, 

It's working now. Thanks so much for your support!
Reply all
Reply to author
Forward
0 new messages