Improved: Unit test case for service - CreateReturnStatus.
Thanks Avnindra Sharma for repoting and Yogesh Naroliya for providing the updated patch.
@@ -101,4 +101,12 @@ class OrderTests extends GroovyScriptTestCase {
Map serviceResult = dispatcher.runSync('createReturnItemShipment', serviceCtx)
assert ServiceUtil.isSuccess(serviceResult)
}
+
+ void testCreateReturnStatus() {
+ Map serviceCtx = [:]
+ serviceCtx.returnId = '1009'
+ serviceCtx.userLogin = EntityQuery.use(delegator).from('UserLogin').where('userLoginId', 'system').cache().queryOne()
+ Map serviceResult = dispatcher.runSync('createReturnStatus', serviceCtx)
+ assert ServiceUtil.isSuccess(serviceResult)
+ }
}
\ No newline at end of file
