stippareddy
14 years agoNew Contributor
Script Assertion
Hi,
I am using soapUI pro 4.0.1 and I am trying to a use script assertion to validate one of the values in the response. This is how my script looks:
-----------------------------
def quota = context.expand( '${getQuotaStatusPrimary#quota}')
def secquota = context.expand( '${getQuotaStatusSecondary#Response#//ADOMO[1]/QUOTA[1]}' )
log.info(quota * (3))
log.info(secquota)
assert secquota == quota * 3
------------------------
I see that the loginfo is printing the quota value 3 times(280028002800) instead of multiplying it with 3(8400). How does the multiply operator work in this case?
Thanks
Sushmita
I am using soapUI pro 4.0.1 and I am trying to a use script assertion to validate one of the values in the response. This is how my script looks:
-----------------------------
def quota = context.expand( '${getQuotaStatusPrimary#quota}')
def secquota = context.expand( '${getQuotaStatusSecondary#Response#//ADOMO[1]/QUOTA[1]}' )
log.info(quota * (3))
log.info(secquota)
assert secquota == quota * 3
------------------------
I see that the loginfo is printing the quota value 3 times(280028002800) instead of multiplying it with 3(8400). How does the multiply operator work in this case?
Thanks
Sushmita