changeset 7:cbeca9e4fbe3

CODETOOLS-7900999 Test list for report with scales
author ersh
date Wed, 06 Aug 2014 18:50:58 +0400
parents 65addecd4439
children f42b2ac06163
files src/classes/com/sun/tdk/jcov/instrument/DeferringMethodClassAdapter.java src/classes/com/sun/tdk/jcov/report/SmartTestService.java src/classes/com/sun/tdk/jcov/report/html/CoverageReport.java
diffstat 3 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/classes/com/sun/tdk/jcov/instrument/DeferringMethodClassAdapter.java	Wed Jul 02 18:43:51 2014 +0400
+++ b/src/classes/com/sun/tdk/jcov/instrument/DeferringMethodClassAdapter.java	Wed Aug 06 18:50:58 2014 +0400
@@ -167,7 +167,7 @@
         }
         MethodVisitor mv = visitMethodCoverage(access, name, desc, signature, exceptions);
 
-        if ("<clinit>".equals(name) && !params.isDynamicCollect() && (k.getPackageName().startsWith("java/") || k.getPackageName().startsWith("javax/"))) {
+        if ("<clinit>".equals(name) && !params.isDynamicCollect() && (k.getPackageName().startsWith("java/lang/"))) {
             mv = new MethodVisitor(Opcodes.ASM4, mv) {
                 public void visitCode() {
                     mv.visitMethodInsn(INVOKESTATIC, "com/sun/tdk/jcov/runtime/Collect", "init", "()V");
--- a/src/classes/com/sun/tdk/jcov/report/SmartTestService.java	Wed Jul 02 18:43:51 2014 +0400
+++ b/src/classes/com/sun/tdk/jcov/report/SmartTestService.java	Wed Aug 06 18:50:58 2014 +0400
@@ -97,6 +97,10 @@
         return result;
     }
 
+    public List<Test> getAllTests(){
+        return  allTests;
+    }
+
     /**
      * <p> Get number of tests in the STS </p>
      *
--- a/src/classes/com/sun/tdk/jcov/report/html/CoverageReport.java	Wed Jul 02 18:43:51 2014 +0400
+++ b/src/classes/com/sun/tdk/jcov/report/html/CoverageReport.java	Wed Aug 06 18:50:58 2014 +0400
@@ -1215,6 +1215,10 @@
                 List<Test> hitlist = testService != null
                         ? testService.getHitTestByClasses(n)
                         : new ArrayList<Test>();
+                if (isAddTestsInfo || isMergeRepGenMode){
+                    hitlist = testService.getAllTests();
+                }
+
                 int i = 1;
                 for (Test httest : hitlist) {
                     String owner = httest.getTestOwner();