< prev index next >

test/gc/logging/TestPrintReferences.java

Print this page
rev 13070 : [mq]: webrev.0a
rev 13071 : [mq]: webrev.1


  46     String refDetailRegex = gcLogTimeRegex + "   Phase2: " + timeRegex +
  47                             gcLogTimeRegex + "   Phase3: " + timeRegex +
  48                             gcLogTimeRegex + "   Cleared: " + countRegex + "\n" +
  49                             gcLogTimeRegex + "   Discovered: " + countRegex + "\n";
  50     String softRefDetailRegex = gcLogTimeRegex + "   Phase1: " + timeRegex +
  51                                 refDetailRegex;
  52 
  53     output.shouldMatch(/* SoftReference processing */
  54                        gcLogTimeRegex + " SoftReference " + timeRegex + softRefDetailRegex +
  55                        /* WeakReference processing */
  56                        gcLogTimeRegex + " WeakReference " + timeRegex + refDetailRegex +
  57                        /* FinalReference processing */
  58                        gcLogTimeRegex + " FinalReference " + timeRegex + refDetailRegex +
  59                        /* PhantomReference processing */
  60                        gcLogTimeRegex + " PhantomReference " + timeRegex + refDetailRegex +
  61                        /* JNI Weak Reference processing */
  62                        gcLogTimeRegex + " JNI Weak Reference " + timeRegex +
  63                        /* Enqueue Reference Lists */
  64                        gcLogTimeRegex + " Enqueue reference lists " + timeRegex +
  65                        /* Enqueued Stats */
  66                        gcLogTimeRegex + "   Counts:  Soft: " + countRegex + "  Weak: " + countRegex +
  67                                         "  Final: " + countRegex + "  Phantom: " + countRegex
  68                        );
  69 
  70     output.shouldHaveExitValue(0);
  71   }
  72 
  73   static class GCTest {
  74     public static void main(String [] args) {
  75       System.gc();
  76     }
  77   }
  78 }


  46     String refDetailRegex = gcLogTimeRegex + "   Phase2: " + timeRegex +
  47                             gcLogTimeRegex + "   Phase3: " + timeRegex +
  48                             gcLogTimeRegex + "   Cleared: " + countRegex + "\n" +
  49                             gcLogTimeRegex + "   Discovered: " + countRegex + "\n";
  50     String softRefDetailRegex = gcLogTimeRegex + "   Phase1: " + timeRegex +
  51                                 refDetailRegex;
  52 
  53     output.shouldMatch(/* SoftReference processing */
  54                        gcLogTimeRegex + " SoftReference " + timeRegex + softRefDetailRegex +
  55                        /* WeakReference processing */
  56                        gcLogTimeRegex + " WeakReference " + timeRegex + refDetailRegex +
  57                        /* FinalReference processing */
  58                        gcLogTimeRegex + " FinalReference " + timeRegex + refDetailRegex +
  59                        /* PhantomReference processing */
  60                        gcLogTimeRegex + " PhantomReference " + timeRegex + refDetailRegex +
  61                        /* JNI Weak Reference processing */
  62                        gcLogTimeRegex + " JNI Weak Reference " + timeRegex +
  63                        /* Enqueue Reference Lists */
  64                        gcLogTimeRegex + " Enqueue reference lists " + timeRegex +
  65                        /* Enqueued Stats */
  66                        gcLogTimeRegex + "   Ref Counts:  Soft: " + countRegex + "  Weak: " + countRegex +
  67                                         "  Final: " + countRegex + "  Phantom: " + countRegex
  68                        );
  69 
  70     output.shouldHaveExitValue(0);
  71   }
  72 
  73   static class GCTest {
  74     public static void main(String [] args) {
  75       System.gc();
  76     }
  77   }
  78 }
< prev index next >