Tips And Tricks for Data-Driven Test Cases

There are several things to know about working with data sources while you are creating data-driven test cases.

Formatting MS Excel worksheets for use as a data source

Use the 'General' format for the columns of your worksheets. Here are specific suggestions for column formats based on the intended data type of the column:

Intended Data Type of Column Excel Column Format
STRING If the column contains only text, no numbers, dates or booleans, then apply the 'General' format. If the column contains text and numbers, then you can still apply the 'General' format if you begin the number strings with a single-quote character. For example: '1003 instead of: 1003. Otherwise, apply the 'Text' format.
INTEGER or REAL ‘General' or 'Number' format.
BOOLEAN ‘General' format. Use only the values TRUE and FALSE.
DATETIME ‘Custom' format: yyyy-mm-dd hh:mm:ss. That agrees with the ISO format used by Silk Test Classic DATETIME values.