Data-driven Virtualization unable to import CSV file in DevTest Portal

Document ID : KB000073092
Last Modified Date : 12/03/2018
Show Technical Document Details
Introduction:
Customer is using json data as response which is saved in  CSV file. When they try to  import a .CSV file into the DevTest Portal to use with the Data Driven feature they get the following error: Error while retrieving columns of a Data Set. (500 JSON Error Parsing Retrofit Error Original message:[[error:[type:TestRunException, message:"Error reading CSV file "]]])

The json response in csv file is as below:
{"Header":{"WSID":"12345","OfficeId":"123","TaxProId":"456","TaxYear":"2016"},"LeafNodes":[{"Key":"1.4","Code":"XYZ","Value":"TRUE"}]}
 
Environment:
All supported DEVTEST environments. 
Instructions:
The single quotes used in CSV file is throwing the Retrofit Error when you try to import the json file. .  
By CSV spec (https://www.loc.gov/preservation/digital/formats/fdd/fdd000323.shtml): "Fields that contain a special character (comma, CR, LF, or double quote), must be "escaped" by enclosing them in double quotes (Hex 22)" 

Change the Response in the CSV file as shown below :

From 

{"Header":{"WSID":"12345","OfficeId":"123","TaxProId":"456","TaxYear":"2016"},"LeafNodes":[{"Key":"1.4","Code":"XYZ","Value":"TRUE"}]}

To   

"{""Header"":{""WSID"":""12345"",""OfficeId"":""123"",""TaxProId"":""456"",""TaxYear"":""2016""},""LeafNodes"":[{""Key"":""1.4"",""Code"":""XYZ"",""Value"":""TRUE""}]}"
Additional Information:
https://www.loc.gov/preservation/digital/formats/fdd/fdd000323.shtml