test/langtools/jdk/jshell/GetResourceTest.java
changeset 50735 2f2af62dfac7
parent 47216 71c04702a3d5
equal deleted inserted replaced
50734:0828a0f6676b 50735:2f2af62dfac7
     1 /*
     1 /*
     2  * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    21  * questions.
    21  * questions.
    22  */
    22  */
    23 
    23 
    24 /*
    24 /*
    25  * @test
    25  * @test
    26  * @bug 8179531
    26  * @bug 8179531 8010319
    27  * @summary Check that ClassLoader.getResource works as expected in the JShell agent.
    27  * @summary Check that ClassLoader.getResource works as expected in the JShell agent.
    28  * @modules jdk.jshell
    28  * @modules jdk.jshell
    29  * @build KullaTesting TestingInputStream
    29  * @build KullaTesting TestingInputStream
    30  * @run testng GetResourceTest
    30  * @run testng GetResourceTest
    31  */
    31  */
    78                    "}",
    78                    "}",
    79                    IGNORE_VALUE,
    79                    IGNORE_VALUE,
    80                    null,
    80                    null,
    81                    DiagCheck.DIAG_OK,
    81                    DiagCheck.DIAG_OK,
    82                    DiagCheck.DIAG_OK,
    82                    DiagCheck.DIAG_OK,
    83                    ste(MAIN_SNIPPET, VALID, VALID, false, null),
    83                    ste(MAIN_SNIPPET, VALID, VALID, true, null),
    84                    ste(testMethod, VALID, OVERWRITTEN, false, MAIN_SNIPPET));
    84                    ste(testMethod, VALID, OVERWRITTEN, false, MAIN_SNIPPET));
    85         assertEval("test()", "true");
    85         assertEval("test()", "true");
    86     }
    86     }
    87 
    87 
    88     public void checkResourceSize() {
    88     public void checkResourceSize() {