Pull variable information from a file?

28 views
Skip to first unread message

Brian Susol

unread,
Jun 17, 2024, 2:02:33 PMJun 17
to Selenium Users
Is it possible to pull variable information that would be used to populate text boxes etc. from a file?  I am currently coding in Java and I do the usual where I am sendkeys = "blah"

Id love to have a file that my users could fill out that the code could read from rather than me updating the code itself. 

Is there another way I am not thinking of?

SiKing

unread,
Jun 18, 2024, 2:13:50 PMJun 18
to Selenium Users
Yes, Java is a full blown language that is capable of reading files: https://www.baeldung.com/reading-file-in-java
From what I have seen, most people will use Excel for such purpose: https://www.baeldung.com/java-microsoft-excel

David

unread,
Jul 1, 2024, 1:31:36 PM (2 days ago) Jul 1
to Selenium Users
Sounds like you're asking about data driven testing (for Java).
Reply all
Reply to author
Forward
0 new messages