Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Cannot see coverage files on linux environment, works fine in windows environment

Mohan Krishna June 4, 2015

Our configuration is  - Jenkins build server trying to call application functionality deployed on a development server(Weblogic).

Below is my build process:

 

1) Source code is instrumented on Jenkins server and build is performed. (To validate I copied the instrumented code to the app server, I extracted the war and confirmed that additional coverage classes were generated.)

2) Instrumented EAR file and coverage DB file are copied to the application server(Weblogic).

3) Run Junit tests that access code(EJB's) deployed on application server.

4) Shutdown application server.

 

Coverage folder has been setup through "initstring" attribute on my clover-setup. I tried both relative and absolute configurations.

 

I even tried the system property setting "clover.initstring" setting on the application server to override the compile-time relative/absolute paths.

 

But, I never saw the coverage files.

 

The same setup works just fine on my local windows server, where-in I run the instrumented build(same build script) and deploy it to local weblogic server instance. I can see the coverage reported for the same tests I ran on the development server.

 

I have read thru the documentation and clover forum Q&A talking about missing coverage, but none similar to my issue.

 

Appreciate any help in this regard!

 

Thanks,

Mohan

 

 

 

 

 

 

 

2 answers

1 accepted

0 votes
Answer accepted
Grzegorz Lewandowski
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 9, 2015

Hello Mohan Krishna,

I'd like to ask you for more information about your configuration:

  1. Which Clover version are you using? If you are using an old version (pre 4.0) please update to the newest 4.0.4 one.
  2. Could you provide us more information about details of your work environments? Is compilation and running application/tests is happening on Linux CI server and for your local development env is on Windows?
  3. How many databases are generated during project instrumentation? Are you using clover-merge? Are you copying all of them to the runtime environment? (in case of Maven for multimodule project there are multiple databases by default) 
  4. Could you specify which initstring exactly were you using? If you have multiple database files maybe clover.initstring.basedir would be more applicable?
  5. Which flush policy are you using? For the default one code coverage will be written on disk after JVM clean shutdown via JVM shutdown hook. Aren't you killing your application server?  Is clover.jar bundled in you web-app or did you put it in the WebLogic's /lib directory or did you pass clover.jar as -Xbootclasspath option?
  6. How are your build plans configured on Jenkins? Is there one plan which compiles, deploys and runs tests or there are separate plans for building, deploying and running tests (and you pass artifacts, such as your WAR/EAR between them)?
  7. Could you please fill-in support ticket on https://support.atlassian.com/ and attach logs from compilation and runtime (application log) from both Jenkins CI and your local environment? Please enable debug logging for a build process (i.e with 'mvn -X' or 'ant -d').

Cheers,

Grzegorz Lewandowski

0 votes
Mohan Krishna June 23, 2015

Thanks Grzegorz 

#1 resolved it. Had to upgrade clover version to 4.0.4.

 

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events