I'm now working on using a JavaScript html to do some tests. And I want to use HtmlUnit to access the page to acquire the running results on the JavaScript webpage. And this page is here(for the page source, you can right-click mouse to see the source):
http://itec.hust.edu.cn/~zhangcw/javascript.html
what I want is to get the running result about the delay value "delay:xxx ms" calculated by the JavaScript on that page. However, when I use HtmlUnit to capture the html, it always capture the original source of that page and doesn't contain the running result. My code is like this:
WebClient webClient = new WebClient();
HtmlPage page = webClient.getPage("http://itec.hust.edu.cn/~zhangcw/javascript.html");
String source = page.asXml();
System.out.println(Source);
The source only contains the JavaScript source codes and html content, not the execution result by the JavaScript on the page. What I should do using HtmlUnit?
My Question is how can I use the HtmlUnit to get the JavaScript running result on the page?
Thanks for reading the text, tough for my English skill.