langtools/test/jdk/jshell/ToolBasicTest.java
changeset 41635 cb3d04878117
parent 41248 2a3e74c5ad8a
child 41852 448273b190ad
equal deleted inserted replaced
41634:3f9c491b05aa 41635:cb3d04878117
   429                     (a) -> assertVariable(a, "int", "a"),
   429                     (a) -> assertVariable(a, "int", "a"),
   430                     (a) -> assertVariable(a, "double", "b", "10", "10.0"),
   430                     (a) -> assertVariable(a, "double", "b", "10", "10.0"),
   431                     (a) -> assertMethod(a, "void f() {}", "()V", "f"),
   431                     (a) -> assertMethod(a, "void f() {}", "()V", "f"),
   432                     (a) -> assertImport(a, "import java.util.stream.*;", "", "java.util.stream.*"),
   432                     (a) -> assertImport(a, "import java.util.stream.*;", "", "java.util.stream.*"),
   433                     (a) -> assertCommand(a, "/save " + startUpFile.toString(), null),
   433                     (a) -> assertCommand(a, "/save " + startUpFile.toString(), null),
   434                     (a) -> assertCommand(a, "/retain start " + startUpFile.toString(), null)
   434                     (a) -> assertCommand(a, "/set start -retain " + startUpFile.toString(), null)
   435             );
   435             );
   436             Path unknown = compiler.getPath("UNKNOWN");
   436             Path unknown = compiler.getPath("UNKNOWN");
   437             test(
   437             test(
   438                     (a) -> assertCommandOutputStartsWith(a, "/retain start " + unknown.toString(),
   438                     (a) -> assertCommandOutputStartsWith(a, "/set start -retain " + unknown.toString(),
   439                             "|  File '" + unknown + "' for '/retain start' is not found.")
   439                             "|  File '" + unknown + "' for '/set start' is not found.")
   440             );
   440             );
   441             test(false, new String[0],
   441             test(false, new String[0],
   442                     (a) -> {
   442                     (a) -> {
   443                         loadVariable(a, "int", "a");
   443                         loadVariable(a, "int", "a");
   444                         loadVariable(a, "double", "b", "10.0", "10.0");
   444                         loadVariable(a, "double", "b", "10.0", "10.0");