Forum Discussion
Hflower
13 years agoOccasional Contributor
After getting the Request EventHandler to work on most request I do I've come full circle now and need to know how to get the Full Path variable interpolated URL from within Groovy
I'm guessing there's something under request but have no idea where to find it.
I've started to do Data Driven tests from a JDBC connection and my Test case has
1. JDBC Data source
2. Template URL REST GET Method - /data/app/ws/rest/companies/entity/v1.0/{CompanyID}
3. Data source Loop
In the REST Step I have put ${MySQL DataSource#CompanyID} as the CompanyID value and now my signature signing code is signing /data/app/ws/rest/companies/entity/v1.0/${MySQL DataSource#CompanyID} instead of /data/app/ws/rest/companies/entity/v1.0/10002 and I fail authentication with the service
So I need to do parameter expansion from within Groovy, I guess by using the context some how?
I'm guessing there's something under request but have no idea where to find it.
I've started to do Data Driven tests from a JDBC connection and my Test case has
1. JDBC Data source
2. Template URL REST GET Method - /data/app/ws/rest/companies/entity/v1.0/{CompanyID}
3. Data source Loop
In the REST Step I have put ${MySQL DataSource#CompanyID} as the CompanyID value and now my signature signing code is signing /data/app/ws/rest/companies/entity/v1.0/${MySQL DataSource#CompanyID} instead of /data/app/ws/rest/companies/entity/v1.0/10002 and I fail authentication with the service
So I need to do parameter expansion from within Groovy, I guess by using the context some how?