Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 83034 Details for
Bug 116487
create performance test harness
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
performance test
clipboard.txt (text/plain), 4.79 KB, created by
Steffen Pingel
on 2007-11-16 01:12:02 EST
(
hide
)
Description:
performance test
Filename:
MIME Type:
Creator:
Steffen Pingel
Created:
2007-11-16 01:12:02 EST
Size:
4.79 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.mylyn.tasks.tests >Index: META-INF/MANIFEST.MF >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.mylyn/org.eclipse.mylyn.tasks.tests/META-INF/MANIFEST.MF,v >retrieving revision 1.34 >diff -u -r1.34 MANIFEST.MF >--- META-INF/MANIFEST.MF 26 Oct 2007 03:58:05 -0000 1.34 >+++ META-INF/MANIFEST.MF 16 Nov 2007 06:11:20 -0000 >@@ -22,9 +22,11 @@ > org.eclipse.mylyn.web.tasks, > org.eclipse.mylyn.monitor.core, > org.eclipse.mylyn, >- org.eclipse.mylyn.web.core >+ org.eclipse.mylyn.web.core, >+ org.eclipse.test.performance > Eclipse-AutoStart: true > Bundle-ClassPath: mylyn-tasklist-tests.jar > Export-Package: org.eclipse.mylyn.tasks.tests, >- org.eclipse.mylyn.tasks.tests.connector >+ org.eclipse.mylyn.tasks.tests.connector, >+ org.eclipse.mylyn.tasks.tests.performance > Bundle-RequiredExecutionEnvironment: J2SE-1.5 >Index: src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryTask.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.mylyn/org.eclipse.mylyn.tasks.tests/src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryTask.java,v >retrieving revision 1.16 >diff -u -r1.16 MockRepositoryTask.java >--- src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryTask.java 26 Jun 2007 01:16:10 -0000 1.16 >+++ src/org/eclipse/mylyn/tasks/tests/connector/MockRepositoryTask.java 16 Nov 2007 06:11:20 -0000 >@@ -12,6 +12,8 @@ > > /** > * @author Mik Kersten >+ * >+ * API-3.0: rename to MockTask > */ > public class MockRepositoryTask extends AbstractTask { > >Index: src/org/eclipse/mylyn/tasks/tests/performance/TaskContainerTest.java >=================================================================== >RCS file: src/org/eclipse/mylyn/tasks/tests/performance/TaskContainerTest.java >diff -N src/org/eclipse/mylyn/tasks/tests/performance/TaskContainerTest.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/mylyn/tasks/tests/performance/TaskContainerTest.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,46 @@ >+/******************************************************************************* >+ * Copyright (c) 2004, 2007 Mylyn project committers and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ *******************************************************************************/ >+ >+package org.eclipse.mylyn.tasks.tests.performance; >+ >+import org.eclipse.mylyn.tasks.core.AbstractTask; >+import org.eclipse.mylyn.tasks.tests.connector.MockRepositoryTask; >+import org.eclipse.test.performance.PerformanceTestCase; >+ >+/** >+ * @author Steffen Pingel >+ */ >+public class TaskContainerTest extends PerformanceTestCase { >+ >+ int counter; >+ >+ private void addChildren(AbstractTask parent, int[] childCount, int depth) { >+ for (int i = 0; i < childCount[depth]; i++) { >+ MockRepositoryTask task = new MockRepositoryTask("task", ++counter + ""); >+ parent.internalAddChild(task); >+ if (depth < childCount.length - 1) { >+ addChildren(task, childCount, depth + 1); >+ } >+ } >+ } >+ >+ public void testContains() { >+ MockRepositoryTask task = new MockRepositoryTask(++counter + ""); >+ addChildren(task, new int[] { 1000, 10, 2 }, 0); >+ >+ for (int i = 0; i < 10; i++) { >+ startMeasuring(); >+ task.contains("handle"); >+ stopMeasuring(); >+ } >+ >+ commitMeasurements(); >+ assertPerformance(); >+ } >+ >+} >Index: src/org/eclipse/mylyn/tasks/tests/AllTasksPerformanceTests.java >=================================================================== >RCS file: src/org/eclipse/mylyn/tasks/tests/AllTasksPerformanceTests.java >diff -N src/org/eclipse/mylyn/tasks/tests/AllTasksPerformanceTests.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/mylyn/tasks/tests/AllTasksPerformanceTests.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,24 @@ >+/******************************************************************************* >+ * Copyright (c) 2004, 2007 Mylyn project committers and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ *******************************************************************************/ >+ >+package org.eclipse.mylyn.tasks.tests; >+ >+import org.eclipse.mylyn.tasks.tests.performance.TaskContainerTest; >+ >+import junit.framework.Test; >+import junit.framework.TestSuite; >+ >+public class AllTasksPerformanceTests { >+ >+ public static Test suite() { >+ TestSuite suite = new TestSuite("Test for org.eclipse.mylyn.tests.performance"); >+ suite.addTestSuite(TaskContainerTest.class); >+ return suite; >+ } >+ >+}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 116487
: 83034 |
83035
|
92635
|
92636
|
92637
|
92638
|
92639
|
92640
|
92641
|
92642
|
92643
|
92644
|
95149
|
95791
|
95792
|
96692
|
96728
|
97960
|
146251