qaf icon indicating copy to clipboard operation
qaf copied to clipboard

Reading integer numbers from xlsx file adds decimal point.

Open ykhudos opened this issue 2 years ago • 2 comments

QAF Version

3.1.0b

Steps To Reproduce

1. Create a test scenario that reads data from Excel file
2. If the data is a number, in my case 5, it is converted into 5.0 in the step execution. 

The described behaviour exists only for .xlsx files. If I save the excel file as .xls, no decimal point is added and 5 in the spreadsheet stays 5 in the test step.

Expected behavior

Data from Excel files should be read exactly as it appears in the Excel file. No conversion/modification.

Actual behavior

If data in Excel spreadsheet is a number, then a .0 is added to the number after QAF reads it. For example 5 in Excel becomes 5.0 in test step.

My project is Maven Junit4/Cucumber5/QAF3.1.0b

ykhudos avatar Jun 02 '22 14:06 ykhudos

If you want it as string set cell/column format string (Text or @) in excel,

cjayswal avatar Jun 03 '22 00:06 cjayswal

Put an ' before the number

Sureshsekar123 avatar Jun 10 '22 19:06 Sureshsekar123