ScalaWebTest is a library for writing ScalaTest/Selenium based integration tests for web applications. It helps you with your basic setup and provides a new and very efficient approach to testing.
The recommended way to manage the encoding and decoding of URLs is to use {@link java.net.URI},
and to convert between these two classes using {@link #toURI()} and {@link URI#toURL()}.
We use URI to construct URLs, additionally this gives us the resolve method to combine baseUriand path. The downside is, that for invalid values, this fails too late. It only fails when the browser tries to transform it, because something like htp://a.com is a valid URI, but not a valid URL.
As the Javadoc states
We use URI to construct URLs, additionally this gives us the
resolve
method to combinebaseUri
andpath
. The downside is, that for invalid values, this fails too late. It only fails when the browser tries to transform it, because something likehtp://a.com
is a valid URI, but not a valid URL.