harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Oleinik (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-2918) Contribution of reliability test suite
Date Mon, 19 Mar 2007 14:30:32 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-2918?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12482101

Oleg Oleinik commented on HARMONY-2918:

I created four new tests covering methods of Thread, ThreadLocal and ThreadGroup:

- api.kernel.thread.ExcptHandlerTest.ExcptHandlerTest covers 
  Thread's UncaughtExceptionHandler and DefaultUncaughtExceptionHandler.

- api.kernel.thread.StackTraceTest.StackTraceTest covers Thread's 
  getStackTrace() and getAllStackTraces().

- api.kernel.thread.ThreadLocalTest.ThreadLocalTest covers ThreadLocal.

- api.kernel.threadgroup.EnumerateTest covers Thread's and 
  ThreadGroup's enumerate().

Test set-up.

1. Unpack src_4_thrd_tests_19_03_07.zip into test suite root 
directory in which there is src/ directory with existing tests). 
This should create new directories and test files.

2. Add these lines to run.api.kernel.xml under <target name="run.api.kernel.thread">:

  <run-pjava-test test="api.kernel.thread.ExcptHandlerTest.ExcptHandlerTest" /> 
  <run-pjava-test test="api.kernel.thread.ThreadLocalTest.ThreadLocalTest" /> 
  <run-pjava-test test="api.kernel.thread.StackTraceTest.StackTraceTest" /> 
  <run-pjava-test test="api.kernel.threadgroup.EnumerateTest" /> 

One can specify test parameters described in the comments in the beginning of 
each test, but, I think, default parameters specified in the tests are sufficient.

3. Compile and run tests as described in README:

cd run
ant -f run.api.kernel.xml run.api.kernel.thread

Test run results.

i tried the tests on WinXP, HDK: svn = r519348, (Mar 17 2007), 
Windows/ia32/msvc 1310, release build (test execution time - 5 minutes):

* api.kernel.thread.ExcptHandlerTest.ExcptHandlerTest exits 
  abnormally on StackOverflowError. If remove the case causing 
  StackOverflowError, the test abnormally completes on ~110 
  iteration showing that it took all available in system memory.
  Passes on RI.

* api.kernel.thread.StackTraceTest.StackTraceTest failed on 161'st 
  iteration with:

  Exception during test execution: java.util.NoSuchElementException
  at java.util.WeakHashMap$HashIterator.next(WeakHashMap.java:162)

  at java.util.AbstractCollection.toArray(AbstractCollection.java)

  at java.lang.ThreadGroup.copyThreads(ThreadGroup.java)
  at java.lang.ThreadGroup.enumerate(ThreadGroup.java:456)
  at java.lang.ThreadGroup.enumerate(ThreadGroup.java:472)

  at java.lang.ThreadGroup.enumerate(ThreadGroup.java)

  at java.lang.Thread.getAllStackTraces(Thread.java)

  Passes on RI.

* api.kernel.thread.ThreadLocalTest.ThreadLocalTest failed on 
  the 1-st iteration with test failure log message:

  Thread ID=3775 checked value of thread ID=943's _instance_ 
  ThreadLocal variable: get() returned wrong object   
  null instead of org.apache.harmony.test.reliability.

  that signals that ThreadLocal's get sometimes return null 
  instead of previously set object.

  Fails on RI with similar message. I failed to find a mistake 
  in the test...

* api.kernel.threadgroup.EnumerateTest hangs on ~150 iteration, 
  but, runs OK if the test operates only with non-daemon Threads 
  and ThreadGroups.

  Passes on RI.

> Contribution of reliability test suite
> --------------------------------------
>                 Key: HARMONY-2918
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2918
>             Project: Harmony
>          Issue Type: Improvement
>          Components: Contributions
>            Reporter: Oleg Oleinik
>         Assigned To: Geir Magnusson Jr
>            Priority: Minor
>         Attachments: DekkerTest.java, DekkerTest.java, reliability_test_suite.zip, src_4_thrd_tests_19_03_07.zip
> Reliability test suite consisting of 72 reliability tests. Covers mainly kernel, nio,
io, net, text, zip classes functionality.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message