add needed synchronization
@@ -222,11 +222,13 @@ public class TestResultAction extends AbstractTestResultAction<TestResultAction>
List<TestAction> result = new ArrayList<TestAction>();
// Added check for null testData to avoid NPE from issue 4257.
if (testData != null) {
+ synchronized (testData) {
for (Data data : testData)
for (TestAction ta : data.getTestAction(object))
if (ta != null)
result.add(ta);
}
+ }
return Collections.unmodifiableList(result);
}
@@ -254,8 +256,10 @@ public class TestResultAction extends AbstractTestResultAction<TestResultAction>
* @since TODO
*/
public void addData(Data data) {
+ synchronized (testData) {
this.testData.add(data);
}
+ }
/**
* Merges an additional test result into this one.
