qaf
qaf copied to clipboard
Test Case gets skipped for data driven scenarios when getting data from test data file
QAF Version
2.1.14
Steps To Reproduce
1. Scenario driven with multiple data from XML/Excel
Expected behavior
Actual behavior
For example : test data have 4 values and the test cases should be executed 4 times with those data. When fetching data from file as String, test cases with last two data gets skipped. Error : Unable to invoke JavaStep with given arguments: enterCreditCardNo[${CCNo}] at When etching data from file as an Object, the value with more than 16 digits gets changed to some different number other than mentioned in the data file.
Is the issue reproducible on runner?
- [] QAS
- [x] Maven
- [ ] Gradle
- [] Ant
- [x] Eclipse
Test case sample
When user enters Credit Card Number as '${CCNo}'
Hi can you please share Step Implementation and different testdata which you are using
Step Implementation : @QAFTestStep(description = "user enters Credit Card Number as {0}") public void enterCreditCardNo(String ccNum) { System.out.println(ccNum); }
Test Data : 45143750934123567830 3247fhfk{}[]||@# 436712387 1234567890123456
With 2.1.14, if you want to provide numbers as string in datafile, you should quote the value. For example example: "45143750934123567830"
On Mon, May 20, 2019, 7:11 AM namraporecha [email protected] wrote:
Step Implementation : @QAFTestStep(description = "user enters Credit Card Number as {0}") public void enterCreditCardNo(String ccNum) { System.out.println(ccNum); }
Test Data : 45143750934123567830 3247fhfk{}[]||@# 436712387 1234567890123456
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/qmetry/qaf/issues/273?email_source=notifications&email_token=AAA3AG6H5SMIMBQDRII76TDPWKWQJA5CNFSM4HN7U652YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODVY6QEQ#issuecomment-494004242, or mute the thread https://github.com/notifications/unsubscribe-auth/AAA3AG47CVQVPHX3BN63MIDPWKWQJANCNFSM4HN7U65Q .
Issue still persist. I tried with quote but it executes for only two test data instead of four available in data file. Getting error for last two data in the file. Test Data in file : "45143750934123567830" 3247fhfk{}[]||@# 436712387 1234567890123456
When user enters Credit Card Number as '436712387'[0.006s ] Unable to invoke JavaStep with given arguments: enterCreditCardNo[${CCNo}] at
When user enters Credit Card Number as '1234567890123456'[0.004s ] Unable to invoke JavaStep with given arguments: enterCreditCardNo[${CCNo}] at
this two test cases are skipped.
Issue still persist. I tried with quote but it executes for only two test data instead of four available in data file. Getting error for last two data in the file. Test Data in file : "45143750934123567830" 3247fhfk{}[]||@# 436712387 1234567890123456
When user enters Credit Card Number as '436712387'[0.006s ] Unable to invoke JavaStep with given arguments: enterCreditCardNo[${CCNo}] at
When user enters Credit Card Number as '1234567890123456'[0.004s ] Unable to invoke JavaStep with given arguments: enterCreditCardNo[${CCNo}] at
this two test cases are skipped.
Sorry, I tried with quote for all numbers in data file. It executes for all the 4 test data in the file. However it fetches numbers with quote.
i am getting the same error.
com.qmetry.qaf.automation.step.StepInvocationException: Unable to invoke JavaStep with given arguments: verifyBoderPickerForArtPresent[${bordercount}] at
Step implementation public void verifyBoderPickerForArtPresent(String count){ int countNo = Integer.parseInt(count); reactArtPdpBorderPicker.verifyPresent(); WebDriverTestCase.verifyTrue(getReactArtPdpBorderPickerTotalOptions().size() ==countNo, String.format("incorrect border options"), String.format("correct border options")); }