Author: schor Date: Thu Jan 11 18:51:35 2018 New Revision: 1820916 URL: http://svn.apache.org/viewvc?rev=1820916&view=rev Log: no jira measure results in microsec to avoid 0 millisec reporting
Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/test/java/org/apache/uima/jcas/impl/JCasHashMapTest.java Modified: uima/uv3/uimaj-v3/trunk/uimaj-core/src/test/java/org/apache/uima/jcas/impl/JCasHashMapTest.java URL: http://svn.apache.org/viewvc/uima/uv3/uimaj-v3/trunk/uimaj-core/src/test/java/org/apache/uima/jcas/impl/JCasHashMapTest.java?rev=1820916&r1=1820915&r2=1820916&view=diff ============================================================================== --- uima/uv3/uimaj-v3/trunk/uimaj-core/src/test/java/org/apache/uima/jcas/impl/JCasHashMapTest.java (original) +++ uima/uv3/uimaj-v3/trunk/uimaj-core/src/test/java/org/apache/uima/jcas/impl/JCasHashMapTest.java Thu Jan 11 18:51:35 2018 @@ -375,7 +375,7 @@ public class JCasHashMapTest extends Tes JCasHashMap m = new JCasHashMap(200); // true = do use cache assertTrue(m.getApproximateSize() == 0); - long start = System.currentTimeMillis(); + long start = System.nanoTime(); for (int i = 0; i < n; i++) { final int key = addrs[i]; m.putIfAbsent(key, k -> TOP._createSearchKey(k)); @@ -386,11 +386,11 @@ public class JCasHashMapTest extends Tes // m.put(fs); // } } - + long stop = System.nanoTime(); assertEquals(m.getApproximateSize(), n); - System.out.format("time for v1 %,d is %,d ms%n", - n, System.currentTimeMillis() - start); + System.out.format("time for v1 %,d is %,d microsecs%n", + n, (stop - start)/1000); m.showHistogram(); }