Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update TestNG to 6.14.2 version to fix false positive test result #1398

Merged
merged 1 commit into from
Mar 16, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 23 additions & 2 deletions test/JLM_Tests/playlist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,15 @@
-XX:SharedCacheHardLimit=16m -Xscmx1m -Xshareclasses:name=testJLM,reset \
-cp $(Q)$(RESOURCES_DIR)$(P)$(TESTNG)$(P)$(TEST_RESROOT)$(D)jlm_tests.jar$(Q) \
org.testng.TestNG -d $(REPORTDIR) $(Q)$(TEST_RESROOT)$(D)testng.xml$(Q) \
-testnames JLM_Tests_interface \
-testnames TestCompilationMXBean,\
TestGarbageCollectorMXBean,\
TestMemoryManagerMXBean,\
TestMemoryMXBean,\
TestOperatingSystemMXBean,\
TestRuntimeMXBean,\
TestThreadMXBean,\
TestClassLoadingMXBean,\
TestMemoryPoolMXBean \
-groups $(TEST_GROUP) \
-excludegroups $(DEFAULT_EXCLUDE); \
$(TEST_STATUS); \
Expand All @@ -61,7 +69,15 @@
-XX:SharedCacheHardLimit=16m -Xscmx1m -Xshareclasses:name=testJLM,reset \
-cp $(Q)$(RESOURCES_DIR)$(P)$(TESTNG)$(P)$(TEST_RESROOT)$(D)jlm_tests.jar$(Q) \
org.testng.TestNG -d $(REPORTDIR) $(Q)$(TEST_RESROOT)$(D)testng.xml$(Q) \
-testnames JLM_Tests_interface \
-testnames TestCompilationMXBean,\
TestGarbageCollectorMXBean,\
TestMemoryManagerMXBean,\
TestMemoryMXBean,\
TestOperatingSystemMXBean,\
TestRuntimeMXBean,\
TestThreadMXBean,\
TestClassLoadingMXBean,\
TestMemoryPoolMXBean \
-groups $(TEST_GROUP) \
-excludegroups $(DEFAULT_EXCLUDE); \
$(TEST_STATUS); \
Expand Down Expand Up @@ -422,6 +438,7 @@
<subset>SE80</subset>
<subset>SE90</subset>
</subsets>
<disabled>https://github.com/eclipse/openj9/issues/480</disabled>
</test>

<test>
Expand Down Expand Up @@ -452,6 +469,7 @@
<subset>SE80</subset>
<subset>SE90</subset>
</subsets>
<disabled>https://github.com/eclipse/openj9/issues/480</disabled>
</test>

<test>
Expand Down Expand Up @@ -482,6 +500,7 @@
<subset>SE80</subset>
<subset>SE90</subset>
</subsets>
<disabled>https://github.com/eclipse/openj9/issues/480</disabled>
</test>

<test>
Expand Down Expand Up @@ -512,6 +531,7 @@
<subset>SE80</subset>
<subset>SE90</subset>
</subsets>
<disabled>https://github.com/eclipse/openj9/issues/480</disabled>
</test>

<test>
Expand Down Expand Up @@ -545,6 +565,7 @@
<subset>SE80</subset>
<subset>SE90</subset>
</subsets>
<disabled>https://github.com/eclipse/openj9/issues/480</disabled>
</test>

<test>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2005, 2017 IBM Corp. and others
* Copyright (c) 2005, 2018 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -116,7 +116,7 @@ protected void setUp() throws Exception {
} catch (Exception me) {
Assert.fail("Unexpected exception in setting up MemoryMXBeanImpl test: " + me.getMessage());
}
logger.info("Starting TestMemoryMXBean tests ..." + "Test MemoryPoolMXBean name = " + testBean.getName());
logger.info("Starting TestMemoryPoolMXBean tests ..." + "Test MemoryPoolMXBean name = " + testBean.getName());
}

// IBM extension method
Expand Down
38 changes: 35 additions & 3 deletions test/JLM_Tests/testng.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>

<!--
Copyright (c) 2016, 2017 IBM Corp. and others
Copyright (c) 2016, 2018 IBM Corp. and others
This program and the accompanying materials are made available under
the terms of the Eclipse Public License 2.0 which accompanies this
Expand All @@ -27,18 +27,50 @@
<listeners>
<listener class-name="org.openj9.test.util.IncludeExcludeTestAnnotationTransformer" />
</listeners>
<test name="JLM_Tests_interface">
<test name="TestCompilationMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestCompilationMXBean" />
</classes>
</test>
<test name="TestGarbageCollectorMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestGarbageCollectorMXBean" />
</classes>
</test>
<test name="TestMemoryManagerMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestMemoryManagerMXBean" />
</classes>
</test>
<test name="TestMemoryMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestMemoryMXBean" />
<class name="org.openj9.test.java.lang.management.TestMemoryPoolMXBean" />
</classes>
</test>
<test name="TestOperatingSystemMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestOperatingSystemMXBean" />
</classes>
</test>
<test name="TestRuntimeMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestRuntimeMXBean" />
</classes>
</test>
<test name="TestThreadMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestThreadMXBean" />
</classes>
</test>
<test name="TestClassLoadingMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestClassLoadingMXBean" />
</classes>
</test>
<test name="TestMemoryPoolMXBean">
<classes>
<class name="org.openj9.test.java.lang.management.TestMemoryPoolMXBean" />
</classes>
</test> <!-- JLM_Tests -->
<test name="JLM_Tests_class">
<classes>
Expand Down
3 changes: 0 additions & 3 deletions test/Java8andUp/build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,6 @@
<src path="${transformerListener}" />
<exclude name="**/Cmvc194280.java" />
<exclude name="**/resources/**"/>
<exclude name="**/gpu/**"/>
<!-- requires special compilation methods -->
<exclude name="**/NoSuchMethod/**" />
<classpath>
Expand All @@ -162,8 +161,6 @@
<!-- PR117298-->
<exclude name="**/Cmvc194280.java" />
<exclude name="**/resources/**"/>
<!-- need to be included when OpenJ9 have them. -->
<exclude name="**/gpu/**"/>
<!-- requires special compilation methods -->
<exclude name="**/NoSuchMethod/**" />
<classpath>
Expand Down
6 changes: 5 additions & 1 deletion test/Java8andUp/playlist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,8 @@
-groups $(TEST_GROUP) \
-excludegroups $(DEFAULT_EXCLUDE); \
$(TEST_STATUS)</command>
<!-- failed intermittent on Windows, Openj9 issue #1454 -->
<platformRequirements>^os.win</platformRequirements>
<levels>
<level>sanity</level>
</levels>
Expand Down Expand Up @@ -1338,7 +1340,8 @@
-groups $(TEST_GROUP) \
-excludegroups $(DEFAULT_EXCLUDE); \
$(TEST_STATUS)</command>
<platformRequirements>^arch.arm</platformRequirements>
<!-- OpenJ9 issue 1421, failed on zos -->
<platformRequirements>^arch.arm,^os.zos</platformRequirements>
<levels>
<level>sanity</level>
</levels>
Expand Down Expand Up @@ -1572,6 +1575,7 @@
-groups $(TEST_GROUP) \
-excludegroups $(DEFAULT_EXCLUDE); \
$(TEST_STATUS)</command>
<platformRequirements>^os.win</platformRequirements>
<levels>
<level>sanity</level>
</levels>
Expand Down
6 changes: 3 additions & 3 deletions test/Java8andUp/src/j9vm/test/jni/PthreadTest.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2015, 2017 IBM Corp. and others
* Copyright (c) 2015, 2018 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -36,9 +36,10 @@ public class PthreadTest {

private static boolean worked = false;


@Test
public void test_destructor() {
worked = attachAndDetach();
AssertJUnit.assertTrue("Thread successfully detached", worked);
}

@BeforeMethod
Expand All @@ -50,7 +51,6 @@ protected void setUp() throws Exception {

@AfterMethod
protected void tearDown() throws Exception {
AssertJUnit.assertTrue("Thread successfully detached", worked);
logger.debug("---------------------------------------------------------");
}

Expand Down
6 changes: 3 additions & 3 deletions test/Java8andUp/src/org/openj9/test/gpu/SortTest.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2013, 2017 IBM Corp. and others
* Copyright (c) 2013, 2018 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -391,12 +391,12 @@ private void test(int deviceId, int size, boolean logResult) {
}
}

@Test(groups = { "level.sanity" })
@Test(groups = { "level.sanity", "level.extended" })
public void testBasic() {
main(new String[] { "-geometric=10,10000000,31" });
}

@Test(groups = { "level.sanity" })
@Test(groups = { "level.sanity", "level.extended" })
public void testPowersOf2() {
main(new String[] { "-geometric=1,8388608,24" });
}
Expand Down
4 changes: 3 additions & 1 deletion test/Java8andUp/testacc.policy
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,7 @@ grant {
// so we can remove the security manager
permission java.lang.RuntimePermission "setSecurityManager";
// Allow the test harness to write the log files
permission java.io.FilePermission "<<ALL FILES>>", "read,write";
permission java.io.FilePermission "<<ALL FILES>>", "read,write,delete";
permission java.util.PropertyPermission "testng.*", "read";
permission java.util.PropertyPermission "fileStringBuffer", "read";
};
2 changes: 0 additions & 2 deletions test/Java8andUp/testng.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
</listeners>
<test name="generalTest">
<classes>
<!-- RTC WI 124170
<class name="org.openj9.test.gpu.SortTest" />
-->
</classes>
</test>
<test name="regression">
Expand Down
2 changes: 0 additions & 2 deletions test/TestConfig/resources/excludes/latest_exclude_SE80.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@

# Exclude tests temporarily

org.openj9.test.java.security.Test_AccessController:test_doPrivilegedWithCombiner4 858 generic-all
org.openj9.test.java.security.Test_AccessController:test_doPrivileged_createAccessControlContext 858 generic-all
org.openj9.test.attachAPI.TestAttachAPI:test_agntld01 238 generic-all
org.openj9.test.attachAPI.TestAttachAPI:test_agntld02 238 generic-all
org.openj9.test.attachAPI.TestAttachAPI:test_agntld03 238 generic-all
Expand Down
2 changes: 0 additions & 2 deletions test/TestConfig/resources/excludes/latest_exclude_SE90.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@
org.openj9.test.vm.Test_MsgHelp:test_loadMessages_EN AN-https://github.ibm.com/runtimes/test/issues/46 generic-all
org.openj9.test.java.lang.Test_Class:test_getModifiers_classTypes JTC-JAT-133182 generic-all
org.openj9.test.java.lang.Test_Class:test_hideUnsafe BPW-https://github.ibm.com/runtimes/test/issues/109 generic-all
org.openj9.test.java.security.Test_AccessController:test_doPrivilegedWithCombiner4 124199 generic-all
org.openj9.test.java.security.Test_AccessController:test_doPrivileged_createAccessControlContext 124199 generic-all
org.openj9.test.java.lang.Test_ClassLoader 134754 generic-all
org.openj9.test.java.lang.Test_Thread:test_getContextClassLoader 125908 generic-all
org.openj9.test.attachAPI.TestAttachAPI:test_agntld01 238 generic-all
Expand Down
4 changes: 2 additions & 2 deletions test/TestConfig/scripts/tools/getDependencies.pl
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@
sha1 => 'e4f1766ce7404a08f45d859fb9c226fc9e41a861'
);
my %testng = (
url => 'http://central.maven.org/maven2/org/testng/testng/6.10/testng-6.10.jar',
url => 'http://central.maven.org/maven2/org/testng/testng/6.14.2/testng-6.14.2.jar',
fname => 'testng.jar',
sha1 => '368d38d0f6906934b572e1a26441b6f47c58b134'
sha1 => '10c93c2c0d165e895a7582dfd8b165f108658db5'
);
my %jcommander = (
url => 'http://central.maven.org/maven2/com/beust/jcommander/1.48/jcommander-1.48.jar',
Expand Down
2 changes: 1 addition & 1 deletion test/cmdLineTests/classesdbgddrext/playlist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
-outputLimit 1000 -explainExcludes -xids all,$(PLATFORM),$(VARIATION) -plats all,$(PLATFORM),$(VARIATION) \
-xlist $(Q)$(TEST_RESROOT)$(D)dbgextddrtests_excludes.xml$(Q) -nonZeroExitWhenError; \
${TEST_STATUS}</command>
<platformRequirements>^os.zos,^os.zos</platformRequirements>
<platformRequirements>^os.zos</platformRequirements>
<levels>
<level>extended</level>
</levels>
Expand Down
2 changes: 1 addition & 1 deletion test/docs/DependentLibs.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-excepti
* javassist-3.20.0-GA.jar
* jcommander-1.48.jar
* junit-4.10.jar
* testng-6.10.jar
* testng-6.14.2.jar

These libs will be downloaded automatically as part of `make compile`
process.
Expand Down