Yes, I have watched Module 20 , Part 12. In this video data provider is used to get data for "CreateLeadTest" fro excel. The username and password column is mentioned under "loginTest". How does the data provider access column data from another test?
[quote:33r8330f]How does the data provider access column data from another test?
[/quote:33r8330f]
it does not. you have to write it again in excel sheet.
Ok. I have seen the complete video, username and password has not been declared again in "createleadtest". It is only mentioned in "logintest" and not written again for every testcase. Attached screenshot for reference.
Please clarify.
put username and password in create lead test too.
tell me if you need more clarification.
Since I have kept different priority to different test cases so want it to run like that. If I want to run end to end test then I will keep 'y' in excel sheet against all these test cases and it will run sequentially. If I want to run a specific test then I will put 'y' for that test and 'n' for the others.
The issue that I am facing is that when I am declaring String testCaseName = "CreateLeadTest"; in the class (not in @Test) the data provide is reading values frm that test only.
If I declare String testCaseName = "CreateLeadTest"; inside @Test then data provider is not reading the value and program do not compile.
How to input different testcase names so that data provider reads accordingly for different test cases.
Login test - Priority 1
create lead - priority 2
convert lead - priority 3