Mercurial > hg > shenandoah-preopenjdk-archive > openjdk8 > nashorn
changeset 951:7caec82669a4
8057742: ant clean test should not fail if one or more external test suites are missing
Reviewed-by: lagergren, hannesw
author | sundar |
---|---|
date | Mon, 08 Sep 2014 15:51:27 +0530 |
parents | b7a2db4de254 |
children | 45f9decf4fb5 |
files | test/script/basic/JDK-8048079_1.js test/script/basic/JDK-8048079_1.js.EXPECTED test/script/basic/JDK-8048079_1a.js test/script/basic/JDK-8048079_1a.js.EXPECTED test/script/basic/JDK-8048079_1b.js test/script/basic/JDK-8048079_1b.js.EXPECTED test/script/basic/JDK-8048079_2.js test/script/basic/JDK-8048079_2.js.EXPECTED test/script/basic/JDK-8048079_2a.js test/script/basic/JDK-8048079_2a.js.EXPECTED test/script/basic/JDK-8048079_2b.js test/script/basic/JDK-8048079_2b.js.EXPECTED test/script/basic/splitter.js test/script/basic/splitter.js.EXPECTED test/script/basic/splitter_prototype.js test/script/basic/splitter_prototype.js.EXPECTED test/script/basic/splitter_yui.js test/script/basic/splitter_yui.js.EXPECTED test/src/jdk/nashorn/internal/test/framework/TestFinder.java |
diffstat | 19 files changed, 216 insertions(+), 83 deletions(-) [+] |
line wrap: on
line diff
--- a/test/script/basic/JDK-8048079_1.js Thu Sep 04 18:47:18 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,35 +0,0 @@ -/* - * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -/** - * JDK-8048079: Persistent code store is broken after optimistic types merge - * - * @test - * @run - * @option -pcc - * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache - * @fork - */ - -load(__DIR__ + 'prototype.js'); -load(__DIR__ + 'yui.js');
--- a/test/script/basic/JDK-8048079_1.js.EXPECTED Thu Sep 04 18:47:18 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -parsed and compiled ok prototype.js -parsed and compiled ok yui-min.js -parsed and compiled ok yui.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_1a.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8048079: Persistent code store is broken after optimistic types merge + * + * @test + * @runif external.prototype + * @option -pcc + * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache + * @fork + */ + +load(__DIR__ + 'prototype.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_1a.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,1 @@ +parsed and compiled ok prototype.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_1b.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8048079: Persistent code store is broken after optimistic types merge + * + * @test + * @runif external.yui + * @option -pcc + * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache + * @fork + */ + +load(__DIR__ + 'yui.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_1b.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,2 @@ +parsed and compiled ok yui-min.js +parsed and compiled ok yui.js
--- a/test/script/basic/JDK-8048079_2.js Thu Sep 04 18:47:18 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,35 +0,0 @@ -/* - * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -/** - * JDK-8048079: Persistent code store is broken after optimistic types merge - * - * @test - * @run - * @option -pcc - * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache - * @fork - */ - -load(__DIR__ + 'prototype.js'); -load(__DIR__ + 'yui.js');
--- a/test/script/basic/JDK-8048079_2.js.EXPECTED Thu Sep 04 18:47:18 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -parsed and compiled ok prototype.js -parsed and compiled ok yui-min.js -parsed and compiled ok yui.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_2a.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8048079: Persistent code store is broken after optimistic types merge. + * Same script as JDK-8048079_1a.js to exercise code cache. + * @test + * @runif external.prototype + * @option -pcc + * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache + * @fork + */ + +load(__DIR__ + 'prototype.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_2a.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,1 @@ +parsed and compiled ok prototype.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_2b.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,34 @@ +/* + * Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * JDK-8048079: Persistent code store is broken after optimistic types merge + * Same script as JDK-8048079_1b.js to exercise code cache again. + * @test + * @runif external.yui + * @option -pcc + * @option -Dnashorn.persistent.code.cache=build/nashorn_code_cache + * @fork + */ + +load(__DIR__ + 'yui.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/JDK-8048079_2b.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,2 @@ +parsed and compiled ok yui-min.js +parsed and compiled ok yui.js
--- a/test/script/basic/splitter.js Thu Sep 04 18:47:18 2014 +0200 +++ b/test/script/basic/splitter.js Mon Sep 08 15:51:27 2014 +0530 @@ -30,7 +30,5 @@ * @fork */ -load(__DIR__ + 'prototype.js'); -load(__DIR__ + 'yui.js'); load(__DIR__ + 'NASHORN-689.js'); load(__DIR__ + 'NASHORN-58.js');
--- a/test/script/basic/splitter.js.EXPECTED Thu Sep 04 18:47:18 2014 +0200 +++ b/test/script/basic/splitter.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -1,6 +1,3 @@ -parsed and compiled ok prototype.js -parsed and compiled ok yui-min.js -parsed and compiled ok yui.js a=10 a=9 a=8
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/splitter_prototype.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Test various scripts with low splitter threshold + * + * @test + * @option -Dnashorn.compiler.splitter.threshold=200 + * @runif external.prototype + * @fork + */ + +load(__DIR__ + 'prototype.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/splitter_prototype.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,1 @@ +parsed and compiled ok prototype.js
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/splitter_yui.js Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,33 @@ +/* + * Copyright (c) 2010, 2013, Oracle and/or its affiliates. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + */ + +/** + * Test various scripts with low splitter threshold + * + * @test + * @option -Dnashorn.compiler.splitter.threshold=200 + * @runif external.yui + * @fork + */ + +load(__DIR__ + 'yui.js');
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/test/script/basic/splitter_yui.js.EXPECTED Mon Sep 08 15:51:27 2014 +0530 @@ -0,0 +1,2 @@ +parsed and compiled ok yui-min.js +parsed and compiled ok yui.js
--- a/test/src/jdk/nashorn/internal/test/framework/TestFinder.java Thu Sep 04 18:47:18 2014 +0200 +++ b/test/src/jdk/nashorn/internal/test/framework/TestFinder.java Mon Sep 08 15:51:27 2014 +0530 @@ -261,14 +261,17 @@ isTest = false; isNotTest = true; break; - case "@runif": - if (System.getProperty(scanner.next()) != null) { + case "@runif": { + final String prop = scanner.next(); + if (System.getProperty(prop) != null) { shouldRun = true; } else { + factory.log("WARNING: (" + prop + ") skipping " + testFile); isTest = false; isNotTest = true; } break; + } case "@run": shouldRun = true; break;