nashorn/test/script/nosecurity/JDK-8080087.js
author chegar
Wed, 10 Feb 2016 22:58:27 +0000
changeset 35743 80ba74046cf1
parent 31093 52472f1b56e4
permissions -rw-r--r--
8148861: Update jaxws to use the new non-inheriting thread-local Thread constructor Reviewed-by: mkos, mchung
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
31093
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     1
/*
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     2
 * Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     4
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     7
 * published by the Free Software Foundation.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     8
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
     9
 * This code is distributed in the hope that it will be useful, but WITHOUT
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    10
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    11
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    12
 * version 2 for more details (a copy is included in the LICENSE file that
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    13
 * accompanied this code).
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    14
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    15
 * You should have received a copy of the GNU General Public License version
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    16
 * 2 along with this work; if not, write to the Free Software Foundation,
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    17
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    18
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    19
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    20
 * or visit www.oracle.com if you need additional information or have any
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    21
 * questions.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    22
 */
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    23
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    24
/**
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    25
 * JDK-8080087: Nashorn $ENV.PWD is originally undefined
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    26
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    27
 * This is to ensure that $ENV.PWD is correctly set on Windows as well as on all
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    28
 * other platforms.
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    29
 *
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    30
 * @test
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    31
 * @option -scripting
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    32
 * @run
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    33
 */
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    34
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    35
if (typeof($ENV.PWD) === 'undefined') {
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    36
    fail('$ENV.PWD is undefined')
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    37
}
52472f1b56e4 8080087: Nashorn $ENV.PWD is originally undefined
mhaupt
parents:
diff changeset
    38