Ant run cmd not working - Not able to initialize the object | Selenium Forum
M
Posted on 10/10/2016
Problem:
Not able to initialize the object:
new ExtentReports(Constants.REPORT_PATH+fileName,true,DisplayOrder.NEWEST_FIRST);
when i am executing from cmd prompt cmd---> "ant run"

Code:
private static ExtentReports extent;
extent = new ExtentReports(Constants.REPORT_PATH+fileName,true,DisplayOrder.NEWEST_FIRST);
<dependency>
<groupId>com.relevantcodes</groupId>
<artifactId>extentreports</artifactId>
<version>2.40.1</version>
</dependency>
Output:
run:
[testng] [TestNG] Running:
[testng] C:\Users\hp\Desktop\testFramework\src\test\resources\Suite_A.xml
[testng]
[testng] gshhsa dp1
[testng] gshhsa dp2
[testng] Test Start from row 1
[testng] colStartRowNum 2
[testng] dataStartRowNum 3
[testng] Total rows are 3
[testng] Total cols are 5
[testng] 1 ExtentManager
[testng]
[testng] ===============================================
[testng] Suite A
[testng] Total tests run: 3, Failures: 3, Skips: 0
[testng] ===============================================

M
Replied on 11/10/2016

Any update?


M
Replied on 12/10/2016

are you getting any error?


M
Replied on 12/10/2016

View messages
| Reply to message
Move to folder



Message history
Author Message
shilpabhapkar
Message subject: Re: error in ant runFolder: Outbox
Exception is not displaying
Not able to initialize the object:
new ExtentReports(Constants.REPORT_PATH+fileName,true,DisplayOrder.NEWEST_FIRST);
when i am executing from cmd prompt cmd---> "ant run"

I figured out this by using
Sop statements
Before and after initializing ExtentReports object


M
Replied on 13/10/2016

Any update


M
Replied on 13/10/2016

i'm not able to understand what the problem is.