I am trying use a simple java class in order to create a browse test to navigate to several URLs, The problem with my code is that each URL, open in a new tab but I would like each URL to open up in the same browser tab. I was told that my current approach is a little bit off. How do most people conduct these types of browse tests using Java? Does anyone have other ideas on how they would do this? The goal is to check about 15-20 URLs of a website, loading each page for about 3 seconds, then moving on to the next URL in the list. My code is below...
import java.awt.Desktop;
import java.net.URI;
public class BrowseBingTest {
public static void main (String args[]) throws Exception {
Desktop d = Desktop.getDesktop();
d.browse(new URI("http://www.bing.com"));
d.browse(new URI("http://www.outlook.com"));
}
}
Aucun commentaire:
Enregistrer un commentaire