Submit and vote on feature ideas.

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.

Enumerate possible data values for each field within swagger

Options
goofy78270
goofy78270 Posts: 133

While I understand we can manually set enumerations of a field in a datasource, and loop through the row values, I was wondering if it was possible to simply loop through the enumerated values of a field from a swagger rather than having to retype the numerous possibilities of each field that contains enumerations. Or, is there a simple way to automatically extract the various enumerated fields into a data source via script or some other export method?

This would also assist in the testing of version changes to the yaml as the user would not have to manually review the enumerated fields and update the data source with any changes.

Comments

  • jakubiak
    jakubiak Posts: 801 admin
    Options

    Unfortunately SOAtest cannot do that for you automatically - you have to set up the values in the data source manually. It is a good suggestion and that capability would be useful, assuming the swagger has specified the values. Question for you - how many out of the total number of fields in your Swagger have enumerated values?

  • goofy78270
    goofy78270 Posts: 133
    Options

    in my swagger of about 12 endpoints and average of 30 fields per endpoint, I would say ~ 45-50 fields in total have enumerations