Skip to content

ddCreateDatasetFromXmlFile (Accessing Contents of and Persisting Files within the "Files" module)

Compatible with:
  • Purpose
  • This command is used to create a DataSet from an Xml File that is present within the "Files" module in the project. The command takes as input two parameters (a) In the "Target" field, the "Xml Filename" and (b) In the "Value" field a DataSet name. This dataset must have been created using the "ddCreateDataSet" command within a test instruction that is executed within the same test but prior to (ahead of) the test instruction which contains the “ddCreateDataSetFromXmlFile" command.
  • When the Dataset used in “Value” field of this command has not been created already anywhere prior within the same test’s runtime before the command “ddCreateDatasetFromXmlFile” gets executed, the test run will get aborted with an error message "For one or more Instructions within the Test Script "" that use the "ddCreateDatasetFromXmlFile" command, the Dataset name provided in the 'Target' field does NOT exist in the scope of the Test Scenario" message.
  • Syntax
  • ddCreateDataSetFromXmlFile(XmlFileName, dataSetName)
  • Target (mandatory)
  • XmlFileName
  • Value (mandatory)
  • dataSetName
  • Return Value
  • N/A
  • Errors & Exceptions   
  • Condition Error/Exception Message
    File doesn't exist in the project The file name provided in the target '"<filename>"' does not exists in the project.
    Malformed Xml content in the file The file provided in the target '"<filename>"' is not a valid xml file .

 


 

Feedback and Knowledge Base