You must be authenticated to access this page.
We can fix it by using "+ nocsrf" in routes file:
GET / controllers.HomeController.index
+ nocsrf
POST /upload controllers.HomeController.upload
Many thanks,
Ram
| "upload file" in { | |
| val tmpPath = JFiles.createTempFile(null, null) | |
| writeFile(tmpPath, "hello") | |
| // http://doc.scalatest.org/3.0.0/index.html#org.scalatest.selenium.WebBrowser | |
| go to s"http://localhost:$port/" | |
| click on name("name") | |
| pressKeys(tmpPath.toAbsolutePath.toString) | |
| submit() | |
| eventually { pageSource mustBe "file size = 5" } | |
| } | |
--
You received this message because you are subscribed to the Google Groups "Play Framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framework+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/play-framework/ef14808b-9610-4fe1-863b-e35ffb3cda23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.