Add helper for navigation with query parameters in UI Unit Test
This PR improved the UI class by adding navigation methods that take query parameters. UI Unit Test base class should also provide such helpers.
@mcollovati Do you have any appropriate workaround to perform a test with navigating to a view with query parameters?
Just don't test such things as public <T extends Component> T navigate(String location, Class<T> expectedTarget); does not allow query parameters in the location-String 😉?
As a workaround, I think you can directly use UI.getCurrent().navigate(Class<? extends T> navigationTarget, QueryParameters queryParameters).
It should work, but you will lose the checks on UI and target view.
To also have the checks, you can create your own navigate(...) method and use reflection to call verifyAndGetUI and validateNavigationTarget.
Thanks, this worked! Somehow didn't had in mind I can just use UI.getCurrent.navigate()...