diff --git a/screening/sourceTest/java/ch/systemsx/cisd/openbis/dss/screening/server/DssServiceRpcScreeningTest.java b/screening/sourceTest/java/ch/systemsx/cisd/openbis/dss/screening/server/DssServiceRpcScreeningTest.java
index de6851a0702846090eae251ac1be163e43a1905a..1e52041836bc8d3940f3e01cd7d4775ba579b7b3 100644
--- a/screening/sourceTest/java/ch/systemsx/cisd/openbis/dss/screening/server/DssServiceRpcScreeningTest.java
+++ b/screening/sourceTest/java/ch/systemsx/cisd/openbis/dss/screening/server/DssServiceRpcScreeningTest.java
@@ -982,10 +982,7 @@ public class DssServiceRpcScreeningTest extends AssertJUnit
         context.checking(new Expectations()
             {
                 {
-                    for (String dataSetCode : dataSetCodes)
-                    {
-                        one(shareIdManager).lock(dataSetCode);
-                    }
+                    one(shareIdManager).lock(Arrays.asList(dataSetCodes));
                     one(shareIdManager).releaseLocks();
                 }
             });