Welcome to the new Parasoft forums! We hope you will enjoy the site and try out some of the new features, like sharing an idea you may have for one of our products or following a category.
Discussion List
Scripting Issue: Trying to get value in adjacent cell in Table Data Source
I have a script which is using a table data source within Virtualize. In that table there are two columns, num and ID. The value of num is extracted from the request via XML databank and is stored as a variable in the responder suite, titled key. Key = num I have another variable that stored the ID value in a variable…
How can I get values from REST path and return it as a string in the response?
For example, I have somehost.com/restapi/v1/value1 and I want it to return value1. I set up REST URL Data Bank and set "Path - 0" to value1. In one of the attribute in the response, I use this Groovy script... import com.parasoft.api.*; boolean customAssertion(Object input, ScriptingContext context) { String value =…
Scripting Issue: Trying to get a particular value in a column
I have a script where I generate a key based on the request. This key is a value listed in the first column in a table, and the script should return the value of the corresponding value next to the key value. Ex: In column 1 my key is A and I need to return the value next to it BC. So far my script results in an error when…
How to set a value of a variable in data source using groovy script
Hi, I have written a groovy script in which I am capturing a path which I want to get set in the data source, so that I can use that path dynamically in my write file.
getGeneratedDataSourceValues returning null
I'm trying to make a script in incoming Request -> payload, but when i try to put some values to use in response i'm receiving a null pointer. I'm getting the data source with context.getGeneratedDataSourceValues(). Anyone have any idea about what could I be doing wrong?
Extracting source IP & values from JSON data bank
Hi, I'm trying to create a proxy basically scenario is 2 endpoints sending info to single proxy and want to capture what endpoint has sent what data in the data source. I want to capture source IP and info from JSON data bank in the data source that can be used as a data source correlation for other responders. Any…
Extract data source value using javascript
I need to extract value of datasource column using Javascript and combine it with other values. I see some examples of Jython in the forum. Can't we achieve this using Javascript in SOATest?
I want to add the amount and assert the total to a value
Hello, SOA test : 9.9.5 I have an API where the response will be the clients accounts details like(accounts name, Category, amount and etc). I want to add all the different accounts "amount" and assert the same with the "total balance" field. please advise. Thank you. regards, Neil
How to change data source values in xml-request before sending?
In SOATest I have a SOAP-test that takes its values from a data source (an Excel-file). How can I change specific values in the request based on values from the data source? Example: The field "CustomerID" needs to have either a random UUID-value or a specific UUID-value. In the Excel-file the field value is set to "Auto"…