I am not using ant/maven or any other supported third party build/test
coverage creation combo (i.e. roll my own) and was wondering how to
get excludes=... really working currently it will exclude the but not
from the HTML coverage report:

#!/bin/tcsh
#
# Copyright (C) 2024 Aryeh M. Friedman
# Copyright (C) 2018-2021 Friedman-Nixon-Wong Enterprises, LLC & contributors

source getVersions.csh

set project=`aesub '$p'`
set tmp=/tmp/$$
set here=`pwd`
set sysLib=/usr/local/share/java/classes;
#sh src/testdata/pt1.sh

sudo rm -rf $here/jacoco.exec
sudo touch $here/jacoco.exec
sudo chmod 777 $here/jacoco.exec

mkdir $tmp
chmod 777 $tmp
cd $tmp

ln -s $here/src src

sudo -u www java
"-javaagent:$sysLib/jacocoagent.jar=destfile=$here/jacoco.exec,jmx=true,excludes=test/**"
-cp 
$here/scrap/www/WEB-INF/lib/$project.jar:$sysLib/thisTest$thisTestVersion.jar:$sysLib/pcCommon$pcCommonVersion.jar:$sysLib/dudes-lang-common$dudeslangcommonVersion.jar
test.TestMain
set stat=$?

cd $here
sudo rm -rf testCoverage
set cf="";
foreach i (`ls -d scrap/obj/java/21/*`)
    if($i == scrap/obj/java/21/mockdata) then
        continue;
    endif

    if($i == scrap/obj/java/21/test) then
        continue;
    endif

    if($i == scrap/obj/java/21/testapps) then
        continue;
    endif

    set cf=`echo '--classfiles'=$i $cf`
end

sudo java -jar $sysLib/jacococli.jar report jacoco.exec $cf
--sourcefiles=src/java --html=testCoverage --quiet
sudo chmod -R 777 testCoverage

sudo rm -rf $tmp
exit $stat


-- 
Aryeh M. Friedman, Lead Developer, http://www.PetiteCloud.org

-- 
You received this message because you are subscribed to the Google Groups 
"JaCoCo and EclEmma Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jacoco/CAGBxaXmu0%2BJfvU%2BQL4VxKzJ5jbsCoWaW5ozSDL0Ku0gRTdO01w%40mail.gmail.com.

Reply via email to