langtools/test/jdk/jshell/ClassMembersTest.java
changeset 38908 f0c186d76c8a
parent 33362 65ec6de1d6b4
child 41940 048d559e9da7
equal deleted inserted replaced
38840:7693aa00e131 38908:f0c186d76c8a
    21  * questions.
    21  * questions.
    22  */
    22  */
    23 
    23 
    24 /*
    24 /*
    25  * @test
    25  * @test
       
    26  * @bug 8139829
    26  * @summary Test access to members of user defined class.
    27  * @summary Test access to members of user defined class.
    27  * @build KullaTesting TestingInputStream ExpectedDiagnostic
    28  * @build KullaTesting TestingInputStream ExpectedDiagnostic
    28  * @run testng/timeout=600 ClassMembersTest
    29  * @run testng/timeout=600 ClassMembersTest
    29  */
    30  */
    30 
    31 
    59         List<String> list = new ArrayList<>();
    60         List<String> list = new ArrayList<>();
    60         SourceCodeAnalysis codeAnalysis = getAnalysis();
    61         SourceCodeAnalysis codeAnalysis = getAnalysis();
    61         String source = input;
    62         String source = input;
    62         while (!source.trim().isEmpty()) {
    63         while (!source.trim().isEmpty()) {
    63             SourceCodeAnalysis.CompletionInfo info = codeAnalysis.analyzeCompletion(source);
    64             SourceCodeAnalysis.CompletionInfo info = codeAnalysis.analyzeCompletion(source);
    64             list.add(info.source);
    65             list.add(info.source());
    65             source = info.remaining;
    66             source = info.remaining();
    66         }
    67         }
    67         return list;
    68         return list;
    68     }
    69     }
    69 
    70 
    70     @Test(dataProvider = "memberTestCase")
    71     @Test(dataProvider = "memberTestCase")