'Unable to locate element using HtmlUnit and WebDriver on Spring Boot
Same title question already exists, however the environment seems to be different.
I'm trying to execute Spring Boot Web MVC test using MockMvc and WebDriver, so I don't need to run Selenium Server.
I created sample project on GitHub as public repository.
I try to impelent the code referencing Spring Framework Document and Spring Boot Document.
The test code works when using MockMvc and HtmlUnit (MessageControllerMockMvcAndHtmlUnitTest.java). However, when I execute the test using MockMvc and WebDriver (MessageControllerMockMvcAndWebDriverTest.java), the error occurs as follows:
java.lang.IllegalStateException: Unable to locate element by name for com.gargoylesoftware.htmlunit.TextPage@~
Does anyone know what is wrong and how to fix it?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
