Play Framework csrf token generation in unit test
问题 I have two unit tests that fails because of "[RuntimeException: Missing CSRF Token]": running(testServer(3333, provideFakeApplication()), () -> { assertThat(WS.url("http://localhost:3333").get().get(3000).getStatus() ).isEqualTo(OK); and running(testServer(3333, provideFakeApplication()), HTMLUNIT, browser -> { browser.goTo("http://localhost:3333"); assert.... How can I add a session with a CSRF token to the WS.url and the browser.goTo? The tests are trying to reach a page that has a form.