public void ShouldGenerateBaseUriWithTerminatingBackslashFromSuppliedAbsoluteUri() { var uriFactory = new UriFactoryWorker("rooms", "{roomId}"); Assert.AreEqual(new Uri("http://restinpractice.com:8080/uk/"), uriFactory.CreateBaseUri(new Uri("http://restinpractice.com:8080/uk/rooms/1234"))); }
public void ThrowsExceptionWhenSuppliedUriDoesNotContainRoutePrefix() { var uriFactory = new UriFactoryWorker("rooms", "{roomId}"); uriFactory.CreateBaseUri(new Uri("http://restinpractice.com:8080/uk/encounters/1234")); }