use of com.vaadin.flow.router.Location in project flow by vaadin.
the class UITest method locationAfterClientNavigation.
@Test
public void locationAfterClientNavigation() {
UI ui = createAndInitTestUI("");
History history = ui.getPage().getHistory();
history.getHistoryStateChangeHandler().onHistoryStateChange(new HistoryStateChangeEvent(history, null, new Location("foo/bar"), NavigationTrigger.HISTORY));
assertEquals("foo/bar", ui.getInternals().getActiveViewLocation().getPath());
}
Aggregations