test/jdk/jdk/jfr/jcmd/TestJcmdLegacy.java
changeset 50225 2942ae532175
parent 50113 caf115bb98ad
child 50745 a390cbb82d47
equal deleted inserted replaced
50224:67066e7971e1 50225:2942ae532175
    25 
    25 
    26 package jdk.jfr.jcmd;
    26 package jdk.jfr.jcmd;
    27 
    27 
    28 import java.io.File;
    28 import java.io.File;
    29 import java.io.IOException;
    29 import java.io.IOException;
    30 import java.nio.file.Files;
       
    31 import java.nio.file.Path;
    30 import java.nio.file.Path;
    32 
    31 
    33 import jdk.jfr.Recording;
    32 import jdk.jfr.Recording;
    34 import jdk.jfr.consumer.RecordedEvent;
    33 import jdk.jfr.consumer.RecordedEvent;
    35 import jdk.jfr.consumer.RecordingFile;
    34 import jdk.jfr.consumer.RecordingFile;
       
    35 import jdk.test.lib.Utils;
    36 import jdk.test.lib.jfr.EventNames;
    36 import jdk.test.lib.jfr.EventNames;
    37 import jdk.test.lib.jfr.FileHelper;
    37 import jdk.test.lib.jfr.FileHelper;
    38 import jdk.test.lib.process.OutputAnalyzer;
    38 import jdk.test.lib.process.OutputAnalyzer;
    39 
    39 
    40 /*
    40 /*
    66         FileHelper.verifyRecording(p);
    66         FileHelper.verifyRecording(p);
    67         verify(p.toPath());
    67         verify(p.toPath());
    68     }
    68     }
    69 
    69 
    70     private static void testAPI() throws IOException, Exception {
    70     private static void testAPI() throws IOException, Exception {
    71         Path p = Files.createTempFile("recording", ".jfr");
    71         Path p = Utils.createTempFile("enable-legacy-event", ".jfr");
    72 
    72 
    73         try (Recording r = new Recording()) {
    73         try (Recording r = new Recording()) {
    74             r.enable(LEGACY_EVENT);
    74             r.enable(LEGACY_EVENT);
    75             r.start();
    75             r.start();
    76             r.stop();
    76             r.stop();