Search code examples
javajavascripthtmlunit

Using HTMLUnit to test Java script


I'm trying to learn how to use HTMLUnit in order to test some website's JavaScripts elements.

I've tried doing some homework and using the HTMLUnit's How-To's but with no success. I get stuck when trying to run my program, I need to choose how to run it and it gives me a list of option which I never handled before. Please help me on this?

All, I get is a console window waiting for some input? Thats not what I was expecting to happen obviously.

enter image description here


Solution

  • Did you try adding @Test above the homePage() method?