Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2012-06-05 08:16:51 +0000
committerEike Stepper2012-06-05 08:16:51 +0000
commit70df22df4bcedc4cc36ffaf34a68aa9e2b7c9bdc (patch)
tree868742e7e19b1d016d6065e2ade8e545efca7965 /plugins
parentb12aed9c8dfad583700aec85387a6380d3bed74d (diff)
downloadcdo-70df22df4bcedc4cc36ffaf34a68aa9e2b7c9bdc.tar.gz
cdo-70df22df4bcedc4cc36ffaf34a68aa9e2b7c9bdc.tar.xz
cdo-70df22df4bcedc4cc36ffaf34a68aa9e2b7c9bdc.zip
[381472] Design a repository administration API
https://bugs.eclipse.org/bugs/show_bug.cgi?id=381472 Make tests tolerant against async event emission
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/util/TestListener.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/util/TestListener.java b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/util/TestListener.java
index 900a4e33e7..817e6da671 100644
--- a/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/util/TestListener.java
+++ b/plugins/org.eclipse.emf.cdo.tests/src/org/eclipse/emf/cdo/tests/util/TestListener.java
@@ -28,17 +28,18 @@ public class TestListener implements IListener
{
}
- public void assertEvent(final EventAssertion assertion) throws Exception
+ public <T extends IEvent> void assertEvent(final EventAssertion<T> assertion) throws Exception
{
final Exception[] exception = { null };
final Error[] error = { null };
new AbstractOMTest.PollingTimeOuter()
{
+ @SuppressWarnings("unchecked")
@Override
protected boolean successful()
{
- IEvent event;
+ T event;
synchronized (events)
{
if (events.size() != 1)
@@ -46,7 +47,7 @@ public class TestListener implements IListener
return false;
}
- event = events.get(0);
+ event = (T)events.get(0);
}
try

Back to the top