< prev index next >

test/jdk/com/sun/tools/jextract/test8222025/ValistUseTest.java

Print this page




  27 
  28 import static org.testng.Assert.assertTrue;
  29 
  30 /*
  31  * @test
  32  * @bug 8222025
  33  * @summary jextract generates reference to underfined type for va_list
  34  * @library ..
  35  * @run testng ValistUseTest
  36  */
  37 public class ValistUseTest extends JextractToolRunner {
  38     @Test
  39     public void test() throws IOException {
  40         Path vaListUseJar = getOutputFilePath("test8222025.jar");
  41         deleteFile(vaListUseJar);
  42         Path va_list_use_H = getInputFilePath("va_list_use.h");
  43         run("-o", vaListUseJar.toString(),
  44             va_list_use_H.toString()).checkSuccess();
  45         try {
  46             Loader loader = classLoader(vaListUseJar);
  47             Class<?> vaListTag = loader.loadClass("clang_support.builtin$$__va_list_tag");
  48             assertTrue(vaListTag != null);
  49         } finally {
  50             deleteFile(vaListUseJar);
  51         }
  52      }
  53 }


  27 
  28 import static org.testng.Assert.assertTrue;
  29 
  30 /*
  31  * @test
  32  * @bug 8222025
  33  * @summary jextract generates reference to underfined type for va_list
  34  * @library ..
  35  * @run testng ValistUseTest
  36  */
  37 public class ValistUseTest extends JextractToolRunner {
  38     @Test
  39     public void test() throws IOException {
  40         Path vaListUseJar = getOutputFilePath("test8222025.jar");
  41         deleteFile(vaListUseJar);
  42         Path va_list_use_H = getInputFilePath("va_list_use.h");
  43         run("-o", vaListUseJar.toString(),
  44             va_list_use_H.toString()).checkSuccess();
  45         try {
  46             Loader loader = classLoader(vaListUseJar);
  47             Class<?> vaListTag = loader.loadClass("clang_support.builtin$_h$__va_list_tag");
  48             assertTrue(vaListTag != null);
  49         } finally {
  50             deleteFile(vaListUseJar);
  51         }
  52      }
  53 }
< prev index next >